/*
 * DrPeyma Meet — visual polish layer
 * Loaded after style.css so the core layout and all JS hooks stay untouched.
 */

:root {
    --polish-radius-sm: 12px;
    --polish-radius-md: 16px;
    --polish-radius-lg: 22px;
    --polish-shadow-soft: 0 12px 34px rgba(20, 36, 47, 0.08);
    --polish-shadow-panel: 0 24px 70px rgba(20, 36, 47, 0.13);
    --polish-highlight: inset 0 1px 0 rgba(255, 255, 255, 0.72);
    --muted: #526875;
}

/* Keep typography and iconography fully local for reliable call controls. */
@font-face {
    font-family: "Yekanbakh";
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("../fonts/Yekanbakh.ttf") format("truetype");
}

@font-face {
    font-family: "Material Icons";
    font-style: normal;
    font-weight: 400;
    font-display: block;
    src: local("Material Icons"), local("Material Icons Regular"),
        url("../fonts/MaterialIcons.woff2") format("woff2");
}

html {
    -webkit-text-size-adjust: 100%;
    color-scheme: light;
}

body {
    -webkit-tap-highlight-color: transparent;
    text-rendering: optimizeLegibility;
    font-synthesis: weight;
}

::selection {
    color: var(--primary-deep);
    background: rgba(17, 128, 106, 0.2);
}

button,
label,
[role="tab"] {
    -webkit-user-select: none;
    user-select: none;
}

button,
.upload-box,
.role-switch span {
    touch-action: manipulation;
}

button:disabled,
input:disabled,
textarea:disabled {
    cursor: not-allowed;
    opacity: 0.58;
}

input,
textarea {
    min-height: 44px;
    border-radius: var(--polish-radius-sm);
    box-shadow: inset 0 1px 2px rgba(20, 36, 47, 0.025);
}

textarea {
    min-height: 96px;
}

input::placeholder,
textarea::placeholder {
    color: #8a99a5;
    opacity: 1;
}

.role-switch input:focus-visible + span {
    outline: 3px solid rgba(37, 99, 235, 0.34);
    outline-offset: 2px;
}

.material-icons {
    flex: 0 0 auto;
    text-rendering: optimizeLegibility;
    font-feature-settings: "liga";
}

/* Elevated, tactile surfaces */
.start-copy {
    border-radius: 28px;
    box-shadow:
        inset 0 0 0 1px rgba(255, 255, 255, 0.13),
        0 30px 90px rgba(5, 30, 38, 0.24);
}

.start-panel,
.clinical-sidebar,
.communication-panel,
.meeting-popover,
.confirm-modal {
    border-color: rgba(205, 221, 228, 0.86);
    border-radius: var(--polish-radius-lg);
    box-shadow: var(--polish-highlight), var(--polish-shadow-panel);
}

.start-panel,
.communication-panel,
.meeting-popover,
.confirm-modal {
    background: rgba(255, 255, 255, 0.94);
    -webkit-backdrop-filter: saturate(145%) blur(18px);
    backdrop-filter: saturate(145%) blur(18px);
}

.consult-header,
.control-bar {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(248, 252, 252, 0.91));
    -webkit-backdrop-filter: saturate(150%) blur(18px);
    backdrop-filter: saturate(150%) blur(18px);
}

@supports not (backdrop-filter: blur(1px)) {
    .start-panel,
    .communication-panel,
    .meeting-popover,
    .confirm-modal,
    .consult-header,
    .control-bar {
        background: #fff;
    }
}

.consult-header {
    padding-inline-start: max(18px, env(safe-area-inset-right, 0px));
    padding-inline-end: max(18px, env(safe-area-inset-left, 0px));
    padding-block-start: calc(10px + env(safe-area-inset-top, 0px));
    box-shadow: 0 10px 30px rgba(20, 36, 47, 0.045);
}

.consult-layout {
    padding-inline-start: max(12px, env(safe-area-inset-right, 0px));
    padding-inline-end: max(12px, env(safe-area-inset-left, 0px));
}

/* Clinical notes and prescriptions are doctor-only surfaces. */
.consult-shell.role-patient .clinical-sidebar,
.consult-shell.role-patient .top-right-clinical-wrap {
    display: none !important;
}

@media screen and (min-width: 1181px) {
    .consult-shell.role-patient .consult-layout {
        grid-template-columns: minmax(360px, 1fr) clamp(320px, 24vw, 380px);
    }

    .consult-shell.role-patient.chat-collapsed .consult-layout {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media screen and (max-width: 1180px) {
    .consult-shell.role-patient .consult-layout {
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: minmax(0, 1fr);
    }
}

.control-bar {
    padding-inline-start: max(18px, env(safe-area-inset-right, 0px));
    padding-inline-end: max(18px, env(safe-area-inset-left, 0px));
    padding-block-end: calc(10px + env(safe-area-inset-bottom, 0px));
    box-shadow: 0 -14px 36px rgba(20, 36, 47, 0.055);
}

.consult-shell {
    grid-template-rows:
        calc(72px + env(safe-area-inset-top, 0px))
        minmax(0, 1fr)
        calc(78px + env(safe-area-inset-bottom, 0px));
}

.visit-start-shell {
    padding-block-start: max(28px, env(safe-area-inset-top, 0px));
    padding-block-end: max(28px, env(safe-area-inset-bottom, 0px));
    padding-inline-start: max(28px, env(safe-area-inset-right, 0px));
    padding-inline-end: max(28px, env(safe-area-inset-left, 0px));
}

.join-overlay {
    padding-block-start: max(18px, env(safe-area-inset-top, 0px));
    padding-block-end: max(18px, env(safe-area-inset-bottom, 0px));
    padding-inline-start: max(18px, env(safe-area-inset-right, 0px));
    padding-inline-end: max(18px, env(safe-area-inset-left, 0px));
}

.brand-logo,
.brand-mark {
    display: block;
    flex: 0 0 auto;
}

.mobile-start-brand {
    display: none;
}

.mobile-status-pill {
    display: none;
}

.drawer-close {
    display: none;
}

.panel-icon,
.patient-avatar,
.empty-state .material-icons,
.video-placeholder .material-icons,
.ai-hero .material-icons {
    border-radius: var(--polish-radius-md);
    box-shadow: var(--polish-highlight);
}

.patient-card,
.visit-metrics div,
.dock-item,
.video-toolbar,
.ai-card,
.meeting-info-card,
.empty-state,
.participant-row,
.attachment-row,
.upload-box {
    border-radius: var(--polish-radius-md);
}

.patient-card {
    background:
        radial-gradient(circle at 100% 0, rgba(255, 255, 255, 0.78), transparent 42%),
        linear-gradient(135deg, #dff2ec, #f8fcfb);
    box-shadow: var(--polish-highlight);
}

.dock-item,
.visit-metrics div,
.video-toolbar,
.ai-card,
.meeting-info-card,
.participant-row,
.attachment-row {
    box-shadow: var(--polish-highlight), 0 8px 24px rgba(20, 36, 47, 0.035);
}

.clinical-tabs,
.people-chat-wrap {
    border-radius: var(--polish-radius-md);
    box-shadow: inset 0 1px 2px rgba(20, 36, 47, 0.045);
}

.clinical-tab,
.panel-tab {
    border-radius: 11px;
}

.status-pill,
.session-code,
.session-clock,
.participant-role,
.link-conf {
    border-radius: 999px;
}

.session-clock,
#visitTimer {
    direction: ltr;
    unicode-bidi: isolate;
    font-variant-numeric: tabular-nums;
}

.status-pill.connected .material-icons {
    animation: polish-status-pulse 2.2s ease-in-out infinite;
}

.status-pill.connecting,
.mobile-status-pill.connecting,
.status-pill.reconnecting,
.mobile-status-pill.reconnecting {
    color: #875a16;
    border-color: rgba(196, 124, 29, 0.24);
    background: #fff8e9;
}

.status-pill.connecting .material-icons,
.mobile-status-pill.connecting .material-icons,
.status-pill.reconnecting .material-icons,
.mobile-status-pill.reconnecting .material-icons {
    color: var(--warning);
    animation: polish-status-pulse 1.4s ease-in-out infinite;
}

.status-pill.disconnected,
.mobile-status-pill.disconnected {
    color: #9f2931;
    border-color: rgba(214, 64, 69, 0.22);
    background: #fff0f1;
}

.status-pill.disconnected .material-icons,
.mobile-status-pill.disconnected .material-icons {
    color: var(--danger);
}

@keyframes polish-status-pulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }

    50% {
        opacity: 0.52;
        transform: scale(0.78);
    }
}

/* Buttons and controls */
.primary-action,
.secondary-action,
.icon-button,
.control-button,
.chip-action,
.quick-chat {
    border-radius: var(--polish-radius-sm);
}

.primary-action {
    background: linear-gradient(135deg, #168d74, #0b6757);
    box-shadow: 0 10px 24px rgba(17, 128, 106, 0.18), var(--polish-highlight);
}

.primary-action.is-loading {
    position: relative;
    color: transparent;
    pointer-events: none;
    opacity: 1;
}

.primary-action.is-loading > * {
    opacity: 0;
}

.primary-action.is-loading::after {
    position: absolute;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.42);
    border-top-color: #fff;
    border-radius: 50%;
    content: "";
    animation: polish-spin 0.7s linear infinite;
}

@keyframes polish-spin {
    to {
        transform: rotate(360deg);
    }
}

.secondary-action,
.icon-button,
.control-button {
    box-shadow: var(--polish-highlight), var(--polish-shadow-soft);
}

.icon-button {
    width: 44px;
    height: 44px;
    min-height: 44px;
}

.control-button.active {
    box-shadow:
        inset 0 0 0 1px rgba(17, 128, 106, 0.08),
        0 10px 26px rgba(17, 128, 106, 0.13);
}

.control-button.danger {
    background: linear-gradient(135deg, #e24a50, #b91c2c);
    box-shadow: 0 12px 28px rgba(185, 28, 44, 0.24);
}

.control-button.recording {
    box-shadow: 0 0 0 4px rgba(214, 64, 69, 0.12), 0 12px 28px rgba(185, 28, 44, 0.22);
}

/* Video and messaging detail */
.video-section {
    border-radius: var(--polish-radius-lg);
}

.video-card {
    border-radius: var(--polish-radius-lg);
    box-shadow: 0 24px 70px rgba(15, 23, 42, 0.26);
}

.video-card video,
.video-placeholder {
    transition: opacity 0.2s ease;
}

.video-card:not(.has-stream) video {
    opacity: 0;
}

.video-card.has-stream .video-placeholder {
    opacity: 0;
    pointer-events: none;
}

.video-card::after {
    position: absolute;
    z-index: 5;
    inset: 0;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: inherit;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
    content: "";
    pointer-events: none;
}

.video-fullscreen {
    position: absolute;
    z-index: 6;
    top: 12px;
    right: 12px;
    width: 38px;
    height: 38px;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: var(--polish-radius-sm);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: rgba(7, 13, 20, 0.58);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    cursor: pointer;
}

.video-fullscreen .material-icons {
    font-size: 21px;
}

@media (pointer: coarse) {
    .video-fullscreen {
        width: 44px;
        height: 44px;
    }
}

.video-label,
.handRaise,
.video-card > img:not(.caller-image) {
    border-radius: var(--polish-radius-sm);
}

.video-wrap,
.clinical-panel,
.chat-message-show,
.show-attach-file,
.in-call-wrap-up {
    overscroll-behavior: contain;
    scrollbar-color: rgba(101, 118, 132, 0.3) transparent;
    scrollbar-width: thin;
}

.message-bubble {
    border-radius: 14px;
}

.message-bubble.mine {
    background: linear-gradient(135deg, #168d74, #0d705e);
    box-shadow: 0 10px 26px rgba(17, 128, 106, 0.16);
}

.ai-disclaimer {
    margin: 0;
    padding: 10px 12px;
    border: 1px solid rgba(196, 124, 29, 0.2);
    border-radius: var(--polish-radius-sm);
    display: flex;
    align-items: flex-start;
    gap: 7px;
    color: #79521b;
    background: #fff9ed;
    font-size: 0.78rem;
    line-height: 1.8;
}

.ai-disclaimer .material-icons {
    margin-top: 2px;
    color: var(--warning);
    font-size: 18px;
}

/* The stock avatar is violet; a restrained hue shift keeps it in the medical teal palette. */
.participant-row img[src*="profile.png"] {
    filter: hue-rotate(-90deg) saturate(0.82);
}

.app-toast {
    bottom: calc(102px + env(safe-area-inset-bottom, 0px));
    border: 1px solid rgba(255, 255, 255, 0.13);
    border-radius: var(--polish-radius-md);
    background: rgba(15, 23, 42, 0.9);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
}

.meeting-heading-cross {
    margin-right: 0;
    margin-inline-start: auto;
}

@media (hover: hover) and (pointer: fine) {
    .dock-item,
    .patient-card,
    .visit-metrics div,
    .video-toolbar {
        transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
    }

    .dock-item:hover,
    .visit-metrics div:hover {
        transform: translateY(-2px);
        border-color: rgba(17, 128, 106, 0.22);
        box-shadow: var(--polish-highlight), 0 16px 36px rgba(20, 36, 47, 0.08);
    }
}

@media (hover: none) {
    .primary-action:hover,
    .secondary-action:hover,
    .icon-button:hover {
        transform: none;
    }
}

@media (pointer: coarse) {
    .primary-action,
    .secondary-action,
    .chip-action,
    .quick-chat,
    .panel-tab,
    .clinical-tab,
    .role-switch span {
        min-height: 44px;
    }
}

@media screen and (max-width: 1180px) {
    .communication-panel {
        top: calc(86px + env(safe-area-inset-top, 0px));
        bottom: calc(96px + env(safe-area-inset-bottom, 0px));
        left: max(14px, env(safe-area-inset-left, 0px));
        opacity: 0;
        visibility: hidden;
        transform: translateX(-18px);
        transition: transform 0.22s ease, opacity 0.2s ease, visibility 0.22s ease;
    }

    .communication-panel.is-open {
        opacity: 1;
        visibility: visible;
        transform: translateX(0);
    }
}

@media screen and (max-width: 960px) {
    .mobile-status-pill {
        min-height: 34px;
        padding: 6px 9px;
        border: 1px solid var(--line);
        border-radius: 999px;
        display: inline-flex;
        align-items: center;
        gap: 5px;
        color: var(--muted);
        background: rgba(246, 250, 251, 0.92);
        font-size: 0.74rem;
        white-space: nowrap;
    }

    .mobile-status-pill .material-icons {
        color: #94a3b8;
        font-size: 12px;
    }

    .mobile-status-pill.connected {
        color: var(--primary-deep);
        border-color: rgba(17, 128, 106, 0.2);
        background: var(--primary-soft);
    }

    .mobile-status-pill.connected .material-icons {
        color: #13a17e;
    }

    .consult-shell {
        grid-template-rows:
            calc(64px + env(safe-area-inset-top, 0px))
            minmax(0, 1fr)
            calc(106px + env(safe-area-inset-bottom, 0px));
    }

    .communication-panel {
        top: calc(76px + env(safe-area-inset-top, 0px));
        bottom: calc(118px + env(safe-area-inset-bottom, 0px));
    }
}

@media screen and (max-width: 640px) {
    .visit-start-shell {
        padding-block-start: max(12px, env(safe-area-inset-top, 0px));
        padding-block-end: max(12px, env(safe-area-inset-bottom, 0px));
        padding-inline-start: max(12px, env(safe-area-inset-right, 0px));
        padding-inline-end: max(12px, env(safe-area-inset-left, 0px));
    }

    .start-copy {
        order: 2;
        min-height: 220px;
        border-radius: 22px;
        background-position: 42% center;
    }

    .visit-start-hero {
        display: flex;
        flex-direction: column;
    }

    .start-panel {
        order: 1;
    }

    .mobile-start-brand {
        display: block;
        width: 112px;
        margin: 0 auto 2px;
    }

    .join-overlay {
        background-position: 42% center;
    }

    .start-panel,
    .clinical-sidebar,
    .communication-panel,
    .meeting-popover,
    .confirm-modal {
        border-radius: 18px;
    }

    .start-panel input,
    .start-panel .primary-action,
    .start-panel .secondary-action,
    .start-panel .role-switch span {
        min-height: 48px;
    }

    .consult-shell {
        grid-template-rows:
            calc(58px + env(safe-area-inset-top, 0px))
            minmax(0, 1fr)
            calc(122px + env(safe-area-inset-bottom, 0px));
    }

    .consult-header {
        padding-inline-start: max(12px, env(safe-area-inset-right, 0px));
        padding-inline-end: max(12px, env(safe-area-inset-left, 0px));
        padding-block-start: calc(10px + env(safe-area-inset-top, 0px));
    }

    .consult-layout {
        padding-inline-start: max(8px, env(safe-area-inset-right, 0px));
        padding-inline-end: max(8px, env(safe-area-inset-left, 0px));
    }

    .control-bar {
        padding-inline-start: max(8px, env(safe-area-inset-right, 0px));
        padding-inline-end: max(8px, env(safe-area-inset-left, 0px));
        padding-block-end: calc(8px + env(safe-area-inset-bottom, 0px));
    }

    .communication-panel {
        top: calc(68px + env(safe-area-inset-top, 0px));
        bottom: calc(132px + env(safe-area-inset-bottom, 0px));
        left: max(10px, env(safe-area-inset-left, 0px));
        right: max(10px, env(safe-area-inset-right, 0px));
        width: auto;
    }

    .meeting-popover {
        top: calc(68px + env(safe-area-inset-top, 0px));
        left: max(10px, env(safe-area-inset-left, 0px));
        right: max(10px, env(safe-area-inset-right, 0px));
        width: auto;
    }

    .app-toast {
        right: max(10px, env(safe-area-inset-right, 0px));
        left: max(10px, env(safe-area-inset-left, 0px));
        bottom: calc(132px + env(safe-area-inset-bottom, 0px));
        max-width: none;
    }

    .patient-card p {
        display: -webkit-box;
        overflow: hidden;
        -webkit-box-orient: vertical;
        -webkit-line-clamp: 2;
    }

    .video-card {
        border-radius: 18px;
    }

    .control-button {
        border-radius: 13px;
    }
}

/* Keyboard access and progressive enhancement states. */
*[hidden] {
    display: none !important;
}

.skip-link {
    position: fixed;
    z-index: 100;
    top: max(10px, env(safe-area-inset-top, 0px));
    inset-inline-start: 12px;
    padding: 9px 14px;
    border: 1px solid rgba(17, 128, 106, 0.28);
    border-radius: 999px;
    color: #fff;
    background: var(--primary-deep);
    box-shadow: var(--polish-shadow-soft);
    transform: translateY(-180%);
    transition: transform 0.18s ease;
}

.skip-link:focus,
.skip-link:focus-visible {
    color: #fff;
    transform: translateY(0);
}

.noscript-message {
    position: fixed;
    z-index: 100;
    top: 50%;
    left: 50%;
    width: min(420px, calc(100vw - 32px));
    padding: 20px 22px;
    border: 1px solid rgba(17, 128, 106, 0.2);
    border-radius: var(--polish-radius-lg);
    color: var(--ink);
    background: rgba(255, 255, 255, 0.97);
    box-shadow: var(--polish-shadow-panel);
    transform: translate(-50%, -50%);
    text-align: center;
    line-height: 1.9;
}

/* On phones the video remains the primary surface; side panels become drawers. */
@media screen and (max-width: 960px) and (orientation: portrait) {
    .consult-layout {
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: minmax(0, 1fr);
    }

    .consult-shell.chat-collapsed .consult-layout {
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: minmax(0, 1fr);
    }

    .video-section {
        grid-row: 1;
        order: 1;
    }

    .clinical-sidebar {
        position: fixed;
        z-index: 24;
        top: calc(76px + env(safe-area-inset-top, 0px));
        right: max(10px, env(safe-area-inset-right, 0px));
        bottom: calc(118px + env(safe-area-inset-bottom, 0px));
        left: max(10px, env(safe-area-inset-left, 0px));
        width: auto;
        max-width: 380px;
        grid-row: auto;
        order: initial;
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transform: translateX(calc(100% + 24px));
        transition: transform 0.24s ease, opacity 0.2s ease, visibility 0.24s ease;
    }

    .clinical-sidebar.is-open {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: translateX(0);
    }

    .clinical-sidebar .drawer-close {
        min-height: 40px;
        padding: 7px 10px;
        border-radius: var(--polish-radius-sm);
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 6px;
        color: var(--muted);
        background: #f3f7f9;
        font-weight: 800;
    }

    .clinical-sidebar .drawer-close .material-icons {
        font-size: 19px;
    }

    .communication-panel.is-open {
        z-index: 24;
    }

    .drawer-backdrop {
        position: fixed;
        z-index: 23;
        inset: 0;
        display: block;
        background: rgba(15, 23, 42, 0.42);
        -webkit-backdrop-filter: blur(3px);
        backdrop-filter: blur(3px);
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transition: opacity 0.2s ease, visibility 0.2s ease;
    }

    .drawer-backdrop:not([hidden]),
    .drawer-backdrop.is-visible {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

    .mobile-drawer-trigger {
        display: inline-flex;
    }
}

@media screen and (max-width: 640px) and (orientation: portrait) {
    .clinical-sidebar {
        top: calc(68px + env(safe-area-inset-top, 0px));
        bottom: calc(132px + env(safe-area-inset-bottom, 0px));
    }
}

@media screen and (min-width: 961px), screen and (max-width: 960px) and (orientation: landscape) {
    .mobile-drawer-trigger {
        display: none;
    }

    .clinical-sidebar {
        position: relative;
        inset: auto;
        width: auto;
        max-width: none;
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: none;
        transition: none;
    }

    .drawer-backdrop {
        display: none !important;
    }
}

@media screen and (max-width: 420px) {
    .brand-cluster > div {
        display: none;
    }

    .brand-mark {
        width: 70px;
    }

    .header-actions {
        gap: 5px;
    }

    .header-actions > .copy_info {
        display: none;
    }

    .mobile-status-pill {
        width: 32px;
        min-height: 32px;
        padding: 0;
        justify-content: center;
    }

    .mobile-status-pill b {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
        white-space: nowrap;
    }

    .video-toolbar-actions .secondary-action {
        padding-inline: 10px;
    }
}

/* Keep the full call usable on short mobile landscape screens. */
@media screen and (max-width: 960px) and (max-height: 620px) and (orientation: landscape) {
    .consult-shell {
        grid-template-rows:
            calc(56px + env(safe-area-inset-top, 0px))
            minmax(0, 1fr)
            calc(68px + env(safe-area-inset-bottom, 0px));
    }

    .consult-layout {
        grid-template-columns: minmax(0, 1fr) minmax(240px, 0.72fr);
        grid-template-rows: minmax(0, 1fr);
    }

    .video-section {
        grid-row: 1;
        grid-column: 1;
    }

    .clinical-sidebar {
        grid-row: 1;
        grid-column: 2;
    }

    .video-wrap {
        grid-auto-rows: minmax(0, 1fr);
    }

    .userbox,
    .video-card {
        min-height: 0;
    }

    .control-bar {
        grid-template-columns: repeat(6, minmax(54px, 1fr));
        grid-auto-rows: 52px;
        padding-block-start: 4px;
        padding-block-end: calc(4px + env(safe-area-inset-bottom, 0px));
    }

    .control-button {
        min-height: 52px;
    }

    .communication-panel {
        top: calc(64px + env(safe-area-inset-top, 0px));
        bottom: calc(76px + env(safe-area-inset-bottom, 0px));
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

@media (forced-colors: active) {
    .video-card::after {
        display: none;
    }

    .primary-action,
    .control-button.danger,
    .message-bubble.mine {
        border: 1px solid ButtonText;
    }
}

/* 1ix Meet — adaptive workspace refresh */
:root {
    --ink-950: #0b1220;
    --ink-800: #1d2939;
    --ink-500: #667085;
    --canvas: #f4f7f9;
    --surface: #ffffff;
    --brand: #0f766e;
    --brand-strong: #0b5f59;
    --brand-soft: #e7f5f2;
    --accent: #f59e0b;
}

.start-body {
    background:
        radial-gradient(circle at 12% 12%, rgba(20, 184, 166, .14), transparent 28rem),
        radial-gradient(circle at 88% 82%, rgba(245, 158, 11, .1), transparent 25rem),
        #f5f8f9;
}

.visit-start-shell {
    max-width: 1440px;
    min-height: 100dvh;
    padding: clamp(20px, 4vw, 60px);
    display: grid;
    align-content: center;
}

.visit-start-hero {
    min-height: auto;
    grid-template-columns: minmax(0, 1.08fr) minmax(420px, .92fr);
    gap: clamp(36px, 7vw, 100px);
    align-items: center;
}

.start-copy h1 {
    max-width: 760px;
    font-size: clamp(3rem, 6.4vw, 6.6rem);
    line-height: .98;
    letter-spacing: -.065em;
    color: var(--ink-950);
    margin-block: 22px 26px;
}

.start-copy h1 span {
    color: var(--brand);
}

.start-copy .lead-text {
    max-width: 650px;
    font-size: clamp(1rem, 1.45vw, 1.25rem);
    line-height: 2;
    color: #475467;
}

.start-copy .brand-logo {
    width: 112px;
    height: auto;
}

.start-panel {
    border: 1px solid rgba(15, 118, 110, .12);
    border-radius: 28px;
    padding: clamp(24px, 3vw, 38px);
    background: rgba(255, 255, 255, .92);
    box-shadow: 0 32px 90px rgba(15, 23, 42, .13), 0 2px 8px rgba(15, 23, 42, .04);
    backdrop-filter: blur(20px);
}

.start-panel .panel-heading {
    margin-bottom: 26px;
}

.meeting-type-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 8px;
}

.meeting-type-card {
    min-width: 0;
    margin: 0;
    cursor: pointer;
}

.meeting-type-card input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.meeting-type-card > span {
    min-height: 92px;
    padding: 12px 8px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 3px;
    text-align: center;
    border: 1px solid #e4e7ec;
    border-radius: 15px;
    color: #475467;
    background: #f9fafb;
    transition: border-color .2s ease, background .2s ease, color .2s ease, box-shadow .2s ease;
}

.meeting-type-card i {
    font-size: 23px;
}

.meeting-type-card b {
    font-size: 12px;
}

.meeting-type-card small {
    max-width: 80px;
    overflow: hidden;
    font-size: 9px;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #98a2b3;
}

.meeting-type-card input:checked + span {
    border-color: rgba(15, 118, 110, .42);
    color: var(--brand-strong);
    background: var(--brand-soft);
    box-shadow: inset 0 0 0 1px rgba(15, 118, 110, .08);
}

.meeting-type-card input:focus-visible + span {
    outline: 3px solid rgba(15, 118, 110, .2);
    outline-offset: 2px;
}

.role-switch b {
    font: inherit;
}

.start-panel .field-group input {
    min-height: 50px;
    border-radius: 13px;
}

.start-panel .primary-action,
.start-panel .secondary-action {
    min-height: 50px;
    border-radius: 13px;
}

.start-panel .primary-action {
    background: var(--brand);
    box-shadow: 0 10px 28px rgba(15, 118, 110, .22);
}

.start-dock {
    margin-top: 36px;
    border-color: rgba(15, 118, 110, .12);
    background: rgba(255, 255, 255, .68);
    backdrop-filter: blur(12px);
}

.consult-body {
    background: #eef2f4;
}

.consult-shell {
    background:
        radial-gradient(circle at 50% -20%, rgba(20, 184, 166, .1), transparent 38rem),
        #eef2f4;
}

.consult-header,
.control-bar {
    border-color: rgba(15, 23, 42, .08);
    background: rgba(255, 255, 255, .9);
    backdrop-filter: blur(20px);
}

.clinical-sidebar,
.communication-panel {
    border-color: rgba(15, 23, 42, .08);
    box-shadow: 0 18px 55px rgba(15, 23, 42, .08);
}

.meeting-mode-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 9px;
    border-radius: 999px;
    color: var(--brand-strong);
    background: var(--brand-soft);
    font-size: 11px;
    font-weight: 800;
}

.meeting-mode-badge .material-icons {
    font-size: 15px;
}

.consult-shell[data-meeting-type="education"] { --brand: #2563eb; --brand-strong: #1d4ed8; --brand-soft: #eaf1ff; }
.consult-shell[data-meeting-type="inspection"] { --brand: #7c3aed; --brand-strong: #6d28d9; --brand-soft: #f1eafe; }
.consult-shell[data-meeting-type="team"] { --brand: #0f766e; --brand-strong: #0f5f59; --brand-soft: #e7f5f2; }
.consult-shell[data-meeting-type="interview"] { --brand: #b45309; --brand-strong: #92400e; --brand-soft: #fff3df; }

@media (max-width: 1100px) {
    .visit-start-hero {
        grid-template-columns: 1fr;
        max-width: 760px;
        margin-inline: auto;
    }

    .start-copy {
        text-align: center;
    }

    .start-copy .lead-text {
        margin-inline: auto;
    }

    .trust-row {
        justify-content: center;
    }
}

@media (max-width: 620px) {
    .visit-start-shell {
        padding: 16px;
        align-content: start;
    }

    .start-copy h1 {
        font-size: clamp(2.65rem, 14vw, 4rem);
    }

    .meeting-type-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .meeting-type-card > span {
        min-height: 82px;
    }

    .start-panel {
        padding: 20px;
        border-radius: 22px;
    }
}

/* UI/UX Pro Max correction — Enterprise Gateway */
.start-body {
    --start-primary: #176b63;
    --start-primary-strong: #10564f;
    --start-primary-soft: #edf7f5;
    --start-ink: #17211f;
    --start-text: #46534f;
    --start-muted: #687570;
    --start-line: #dfe6e3;
    --start-surface: #ffffff;
    background: #f6f8f7 !important;
}

.start-body .visit-start-shell {
    width: min(100%, 1480px);
    padding: clamp(24px, 4vw, 64px);
}

.start-body .visit-start-hero {
    grid-template-columns: minmax(440px, .9fr) minmax(600px, 1.1fr);
    gap: clamp(40px, 5vw, 76px);
}

.start-body .start-copy {
    min-height: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    overflow: visible !important;
    color: var(--start-ink) !important;
    background: none !important;
    box-shadow: none !important;
    text-align: right !important;
}

.start-body .start-copy::before,
.start-body .start-copy::after {
    display: none !important;
}

.start-body .start-copy .brand-logo {
    width: 104px;
    height: auto;
    margin: 0 0 40px;
    filter: none !important;
}

.start-body .start-copy .eyebrow {
    margin-bottom: 18px;
    color: var(--start-primary-strong) !important;
    background: var(--start-primary-soft) !important;
}

.start-body .start-copy h1 {
    max-width: 600px;
    margin: 0;
    color: var(--start-ink) !important;
    font-size: clamp(2.65rem, 4.1vw, 4.75rem);
    font-weight: 900;
    line-height: 1.16;
    letter-spacing: -.045em;
    text-shadow: none !important;
}

.start-body .start-copy .lead-text {
    max-width: 610px;
    margin-top: 22px;
    color: var(--start-text) !important;
    font-size: 16px;
    line-height: 2;
    text-shadow: none !important;
}

.start-body .trust-row {
    margin-top: 24px;
    justify-content: flex-start;
    gap: 8px;
}

.start-body .trust-row span {
    min-height: 44px;
    padding: 7px 9px 7px 13px !important;
    border: 1px solid var(--start-line) !important;
    border-radius: 11px;
    gap: 7px;
    color: #43514d !important;
    background: var(--start-surface) !important;
}

.start-body .trust-row span b {
    font-size: 11px;
    font-weight: 850;
}

.start-body .trust-row i {
    border: 0;
    color: var(--start-primary);
    background: var(--start-primary-soft);
}

.start-body .start-visual {
    margin-top: 24px;
    border-color: var(--start-line);
    border-radius: 20px;
    background: #e8ece9;
    box-shadow: 0 18px 50px rgba(30, 49, 44, .1);
}

.start-body .start-visual img {
    height: clamp(210px, 21vw, 300px);
    object-position: center 45%;
}

.start-body .start-visual figcaption {
    right: 14px;
    bottom: 14px;
    left: 14px;
    padding: 12px 14px;
    border: 0;
    border-radius: 12px;
    color: #fff;
    background: rgba(20, 34, 30, .84);
    backdrop-filter: blur(10px);
}

.start-body .start-visual figcaption b {
    font-size: 13px;
}

.start-body .start-visual figcaption span {
    font-size: 11px;
}

.start-body .start-panel {
    min-height: 620px;
    padding: clamp(28px, 3vw, 40px);
    border: 1px solid var(--start-line);
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 28px 80px rgba(24, 39, 35, .1);
}

.start-body .start-panel > .panel-heading {
    margin-bottom: 30px;
    grid-template-columns: 48px minmax(0, 1fr) 62px;
}

.start-body .start-panel .panel-heading h2 {
    font-size: 20px;
    line-height: 1.5;
}

.start-body .start-panel .panel-heading p {
    font-size: 12px;
    line-height: 1.6;
}

.start-body .step-counter {
    display: flex;
    align-items: baseline;
    justify-content: flex-end;
    gap: 3px;
}

.start-body .meeting-kind-field > span {
    margin-bottom: 14px;
    font-size: 14px;
}

.start-body .meeting-type-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
}

.start-body .meeting-type-card > span {
    min-height: 118px;
    padding: 18px 8px 14px;
    border-radius: 14px;
}

.start-body .meeting-type-card i {
    font-size: 26px;
}

.start-body .meeting-type-card b {
    font-size: 13px;
}

.start-body .meeting-type-card small {
    max-width: none;
    font-size: 10px;
}

.start-body .meeting-type-card > span::after {
    top: 10px;
    left: 10px;
}

.start-body .type-preview {
    min-height: 134px;
    margin-top: 18px;
    padding: 18px;
    border-color: var(--start-line);
    background: #fafcfb;
}

.start-body .type-preview strong {
    font-size: 14px;
}

.start-body .type-preview p {
    font-size: 12px;
}

.start-body .type-feature-list span {
    min-height: 28px;
    padding: 5px 9px;
    display: inline-flex;
    align-items: center;
    color: #3f514c;
    background: #eef3f1;
    font-size: 11px;
}

.start-body .step-next {
    min-height: 52px;
    margin-top: 20px;
    background: var(--start-primary);
    box-shadow: 0 10px 28px rgba(23, 107, 99, .18);
}

.start-body .step-next:hover {
    background: var(--start-primary-strong);
}

.start-body .start-dock {
    margin-top: 40px;
    display: grid;
    grid-template-columns: minmax(210px, 1.15fr) repeat(3, minmax(220px, 1fr));
    gap: 12px;
}

.start-body .feature-heading {
    padding: 20px 0 20px 24px;
    align-self: center;
}

.start-body .feature-heading span {
    color: var(--start-primary);
    font-size: 11px;
    font-weight: 850;
}

.start-body .feature-heading h2 {
    margin: 5px 0 0;
    color: var(--start-ink);
    font-size: 20px;
    font-weight: 900;
}

.start-body .dock-item {
    position: relative;
    min-height: 112px;
    padding: 20px;
    border: 1px solid var(--start-line) !important;
    border-radius: 16px;
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr);
    align-items: center;
    gap: 12px;
    background: #fff;
    box-shadow: 0 8px 26px rgba(27, 44, 39, .055);
    transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}

.start-body .dock-item:hover {
    border-color: #b9d3cd !important;
    box-shadow: 0 14px 34px rgba(27, 44, 39, .09);
    transform: translateY(-2px);
}

.start-body .dock-item > .material-icons {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--start-primary);
    background: var(--start-primary-soft);
    font-size: 21px;
}

.start-body .dock-item strong {
    display: block;
    color: var(--start-ink);
    font-size: 13px;
}

.start-body .dock-item small {
    display: block;
    margin-top: 5px;
    color: var(--start-muted);
    font-size: 11px;
    line-height: 1.7;
}

.start-body .feature-number {
    position: absolute;
    top: 10px;
    left: 12px;
    color: #a5b0ac;
    font-size: 9px;
    font-variant-numeric: tabular-nums;
}

@media (max-width: 1180px) {
    .start-body .visit-start-hero {
        max-width: 780px;
        grid-template-columns: 1fr;
    }

    .start-body .start-copy {
        max-width: 700px;
    }

    .start-body .start-dock {
        max-width: 780px;
        margin-inline: auto;
        grid-template-columns: repeat(3, 1fr);
    }

    .start-body .feature-heading {
        grid-column: 1 / -1;
        padding: 8px 0 4px;
    }
}

@media (max-width: 720px) {
    .start-body .visit-start-shell {
        padding: 20px 14px 32px;
    }

    .start-body .start-copy .brand-logo {
        margin-bottom: 24px;
    }

    .start-body .start-copy h1 {
        font-size: clamp(2.25rem, 11vw, 3.3rem);
        letter-spacing: -.035em;
    }

    .start-body .start-copy .lead-text {
        font-size: 15px;
    }

    .start-body .trust-row {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
    }

    .start-body .trust-row span {
        min-width: 0;
        padding: 7px !important;
        flex-direction: column;
        text-align: center;
    }

    .start-body .trust-row span b {
        font-size: 9px;
    }

    .start-body .start-visual img {
        height: 210px;
    }

    .start-body .start-panel {
        min-height: 0;
        padding: 18px;
    }

    .start-body .meeting-type-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .start-body .meeting-type-card:last-child {
        grid-column: 1 / -1;
    }

    .start-body .meeting-type-card > span {
        min-height: 96px;
    }

    .start-body .start-dock {
        display: grid;
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .start-body .feature-heading {
        grid-column: 1;
    }

    .start-body .dock-item {
        min-height: 92px;
    }
}

/* Start flow v2 — isolated from the legacy meeting styles */
.start-body {
    min-height: 100dvh;
    overflow-x: hidden;
    color: #18211f;
    background: #f7f8f6;
}

.start-body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background:
        linear-gradient(90deg, rgba(21, 94, 87, .035) 1px, transparent 1px),
        linear-gradient(rgba(21, 94, 87, .035) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: linear-gradient(to bottom, #000, transparent 85%);
}

.start-body .visit-start-shell {
    width: min(100%, 1360px);
    min-height: 100dvh;
    margin: 0 auto;
    padding: clamp(28px, 5vw, 72px);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.start-body .visit-start-hero {
    width: 100%;
    min-height: 0;
    display: grid;
    grid-template-columns: minmax(300px, .78fr) minmax(560px, 1.22fr);
    gap: clamp(48px, 7vw, 104px);
    align-items: center;
}

.start-body .start-copy {
    align-self: center;
    padding: 0;
    color: #18211f;
}

.start-body .start-copy .brand-logo {
    width: 102px;
    margin-bottom: 44px;
}

.start-body .start-copy .eyebrow {
    width: fit-content;
    margin: 0 0 16px;
    padding: 7px 11px;
    border: 1px solid #d8e5e1;
    border-radius: 999px;
    color: #155e57;
    background: #f0f7f5;
    font-size: 12px;
    font-weight: 850;
    letter-spacing: 0;
}

.start-body .start-copy h1 {
    max-width: 560px;
    margin: 0 0 24px;
    color: #13201d;
    font-size: clamp(3rem, 5.2vw, 5.4rem);
    font-weight: 950;
    line-height: 1.08;
    letter-spacing: -.055em;
}

.start-body .start-copy h1 span {
    color: #155e57;
}

.start-body .start-copy .lead-text {
    max-width: 540px;
    margin: 0;
    color: #586461;
    font-size: 16px;
    line-height: 2;
}

.start-body .trust-row {
    margin-top: 32px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px 20px;
}

.start-body .trust-row span {
    padding: 0;
    border: 0;
    color: #66736f;
    background: transparent;
    font-size: 12px;
}

.start-body .trust-row i {
    width: 26px;
    height: 26px;
    border: 1px solid #dce5e2;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #155e57;
    background: #fff;
    font-size: 15px;
}

.start-visual {
    position: relative;
    margin: 34px 0 0;
    overflow: hidden;
    border: 1px solid #dfe5e2;
    border-radius: 18px;
    background: #ede9df;
    box-shadow: 0 18px 42px rgba(32, 42, 39, .1);
}

.start-visual::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .5);
}

.start-visual img {
    width: 100%;
    height: clamp(190px, 20vw, 260px);
    display: block;
    object-fit: cover;
    object-position: center 44%;
}

.start-visual figcaption {
    position: absolute;
    right: 12px;
    bottom: 12px;
    left: 12px;
    padding: 11px 13px;
    border: 1px solid rgba(255, 255, 255, .42);
    border-radius: 11px;
    color: #fff;
    background: rgba(20, 33, 30, .78);
    backdrop-filter: blur(12px);
}

.start-visual figcaption b,
.start-visual figcaption span {
    display: block;
}

.start-visual figcaption b {
    font-size: 11px;
}

.start-visual figcaption span {
    margin-top: 2px;
    color: rgba(255, 255, 255, .76);
    font-size: 9px;
}

.start-body .start-panel {
    width: 100%;
    min-height: 570px;
    margin: 0;
    padding: clamp(26px, 3vw, 38px);
    border: 1px solid #e0e5e3;
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 24px 70px rgba(24, 33, 31, .09);
    backdrop-filter: none;
}

.start-body .start-panel > .panel-heading {
    min-height: 54px;
    margin: 0 0 28px;
    padding-bottom: 22px;
    border-bottom: 1px solid #edf0ef;
    display: grid;
    grid-template-columns: 46px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
}

.start-body .start-panel .panel-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #155e57;
    background: #eaf4f1;
    font-size: 22px;
}

.start-body .start-panel .panel-heading h2 {
    margin: 0 0 3px;
    color: #17201e;
    font-size: 19px;
    font-weight: 950;
}

.start-body .start-panel .panel-heading p {
    margin: 0;
    color: #7b8582;
    font-size: 12px;
}

.step-counter {
    min-width: 54px;
    direction: rtl;
    text-align: left;
    color: #98a19f;
    font-size: 11px;
}

.step-counter b {
    color: #155e57;
    font-size: 18px;
}

.form-step {
    animation: step-in .24s ease both;
}

.form-step[hidden] {
    display: none !important;
}

@keyframes step-in {
    from { opacity: 0; transform: translateY(7px); }
    to { opacity: 1; transform: translateY(0); }
}

.start-body .meeting-kind-field {
    margin: 0;
}

.start-body .meeting-kind-field > span {
    margin-bottom: 12px;
    color: #34403d;
    font-size: 13px;
    font-weight: 900;
}

.start-body .meeting-type-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 8px;
}

.start-body .meeting-type-card > span {
    min-height: 96px;
    padding: 13px 6px 11px;
    border: 1px solid #e2e7e5;
    border-radius: 14px;
    color: #58635f;
    background: #fbfcfb;
    box-shadow: none;
}

.start-body .meeting-type-card > span::after {
    content: "";
    width: 17px;
    height: 17px;
    position: absolute;
    top: 8px;
    left: 8px;
    border: 1px solid #d7dddb;
    border-radius: 50%;
    background: #fff;
}

.start-body .meeting-type-card > span {
    position: relative;
}

.start-body .meeting-type-card i {
    margin-bottom: 4px;
    color: #53615d;
    font-size: 24px;
}

.start-body .meeting-type-card b {
    color: #293431;
    font-size: 12px;
    font-weight: 900;
}

.start-body .meeting-type-card small {
    width: 100%;
    font-size: 9px;
    color: #8a9491;
}

.start-body .meeting-type-card input:checked + span {
    border-color: #26766f;
    color: #155e57;
    background: #eff7f5;
    box-shadow: 0 0 0 2px rgba(21, 94, 87, .08);
}

.start-body .meeting-type-card input:checked + span::after {
    border: 5px solid #26766f;
}

.start-body .meeting-type-card input:checked + span i,
.start-body .meeting-type-card input:checked + span b {
    color: #155e57;
}

.type-preview {
    min-height: 116px;
    margin-top: 16px;
    padding: 18px;
    border: 1px solid #e4e9e7;
    border-radius: 16px;
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 14px;
    background: #fafbf9;
}

.type-preview > .material-icons {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #155e57;
    background: #e7f2ef;
    font-size: 21px;
}

.type-preview strong {
    display: block;
    color: #26312e;
    font-size: 13px;
    font-weight: 950;
}

.type-preview p {
    margin: 4px 0 10px;
    color: #737e7b;
    font-size: 11px;
    line-height: 1.7;
}

.type-feature-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.type-feature-list span {
    padding: 4px 7px;
    border-radius: 7px;
    color: #4f5f5a;
    background: #edf1ef;
    font-size: 10px;
    font-weight: 750;
}

.type-feature-list i {
    margin-left: 3px;
    color: #268277;
    font-size: 11px;
    vertical-align: -2px;
}

.start-body .step-next {
    width: 100%;
    min-height: 50px;
    margin-top: 18px;
    border-radius: 12px;
}

.step-back {
    margin: -6px 0 14px;
    padding: 5px 0;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #65716e;
    background: transparent;
    border: 0;
    cursor: pointer;
    font-size: 11px;
    font-weight: 800;
}

.step-back .material-icons {
    font-size: 16px;
}

.selected-type-summary {
    margin-bottom: 18px;
    padding: 11px 13px;
    border: 1px solid #dce8e4;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f1f7f5;
}

.selected-type-summary > .material-icons {
    width: 34px;
    height: 34px;
    border-radius: 9px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #155e57;
    background: #dfeeea;
    font-size: 18px;
}

.selected-type-summary small,
.selected-type-summary strong {
    display: block;
}

.selected-type-summary small {
    color: #7a8582;
    font-size: 9px;
}

.selected-type-summary strong {
    margin-top: 1px;
    color: #2b3935;
    font-size: 12px;
    font-weight: 900;
}

.start-body #meetingDetailsStep {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 15px 12px;
}

.start-body #meetingDetailsStep .step-back,
.start-body #meetingDetailsStep .selected-type-summary,
.start-body #meetingDetailsStep .form-actions,
.start-body #meetingDetailsStep .form-note {
    grid-column: 1 / -1;
}

.start-body #meetingDetailsStep .field-group {
    margin: 0;
    gap: 6px;
}

.start-body #meetingDetailsStep .field-group > span {
    color: #424d4a;
    font-size: 11px;
    font-weight: 850;
}

.start-body #meetingDetailsStep input {
    width: 100%;
    min-height: 46px;
    padding: 10px 12px;
    border: 1px solid #dfe5e3;
    border-radius: 11px;
    color: #202a27;
    background: #fff;
    font-size: 12px;
    box-shadow: none;
}

.start-body #meetingDetailsStep input::placeholder {
    color: #a0aaa7;
}

.start-body #meetingDetailsStep input:focus {
    border-color: #277970;
    outline: 3px solid rgba(21, 94, 87, .1);
}

.start-body #meetingDetailsStep .role-switch {
    gap: 7px;
    padding: 0;
    background: transparent;
}

.start-body #meetingDetailsStep .role-switch span {
    min-height: 46px;
    padding: 8px;
    border: 1px solid #dfe5e3;
    border-radius: 11px;
    color: #54605d;
    background: #fafbfa;
    font-size: 11px;
}

.start-body #meetingDetailsStep .role-switch input:checked + span {
    border-color: #277970;
    color: #155e57;
    background: #eff7f5;
}

.start-body #meetingDetailsStep .form-actions {
    margin-top: 3px;
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr);
    gap: 8px;
}

.start-body #meetingDetailsStep .form-actions button {
    min-height: 48px;
    border-radius: 11px;
    font-size: 11px;
}

.start-body .start-dock {
    width: 100%;
    margin-top: 30px;
    padding: 0;
    border: 0;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
}

.start-body .dock-item {
    padding: 0 20px;
    border-left: 1px solid #e0e5e3;
}

.start-body .dock-item:last-child {
    border-left: 0;
}

.start-body .dock-item > .material-icons {
    color: #71807c;
    background: transparent;
}

/* Purpose-built in-call workspaces */
.adaptive-workspace {
    min-height: 0;
    display: grid;
    align-content: start;
    gap: 11px;
}

.adaptive-workspace[hidden] {
    display: none !important;
}

.workspace-head {
    padding: 13px;
    border: 1px solid color-mix(in srgb, var(--brand) 22%, #e4e7ec);
    border-radius: 13px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--brand-strong);
    background: var(--brand-soft);
}

.workspace-head > .material-icons {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: var(--brand);
    font-size: 19px;
}

.workspace-head b,
.workspace-head small {
    display: block;
}

.workspace-head b {
    color: var(--brand-strong);
    font-size: 12px;
    font-weight: 950;
}

.workspace-head small {
    margin-top: 2px;
    color: #687671;
    font-size: 9px;
}

.workspace-section {
    padding: 13px;
    border: 1px solid #e5e9e7;
    border-radius: 13px;
    display: grid;
    gap: 10px;
    background: #fff;
}

.workspace-section label {
    margin: 0;
    display: grid;
    gap: 6px;
    color: #45514d;
    font-size: 10px;
    font-weight: 850;
}

.workspace-section input:not([type="range"]):not([type="checkbox"]),
.workspace-section textarea,
.workspace-section select {
    width: 100%;
    min-height: 38px;
    padding: 9px 10px;
    border: 1px solid #dfe5e2;
    border-radius: 9px;
    color: #26312e;
    background: #fbfcfc;
    font-family: inherit;
    font-size: 10px;
    line-height: 1.7;
    resize: vertical;
}

.workspace-section textarea:focus,
.workspace-section input:focus,
.workspace-section select:focus {
    border-color: var(--brand);
    outline: 3px solid color-mix(in srgb, var(--brand) 13%, transparent);
}

.workspace-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.section-label,
.section-title b {
    color: #34403c;
    font-size: 10px;
    font-weight: 950;
}

.section-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.section-title span {
    padding: 3px 7px;
    border-radius: 99px;
    color: var(--brand-strong);
    background: var(--brand-soft);
    font-size: 9px;
    font-weight: 900;
}

.score-range {
    width: 100%;
    accent-color: var(--brand);
    cursor: pointer;
}

.range-labels {
    display: flex;
    justify-content: space-between;
    color: #8a9692;
    font-size: 8px;
}

.evidence-list {
    display: grid;
    gap: 6px;
}

.evidence-list label {
    min-height: 34px;
    padding: 7px 9px;
    border: 1px solid #e6eae8;
    border-radius: 8px;
    display: flex;
    grid-template-columns: none;
    align-items: center;
    gap: 7px;
    color: #53605c;
    background: #fafbfa;
    cursor: pointer;
}

.evidence-list input {
    accent-color: var(--brand);
}

.workspace-alert {
    padding: 10px 11px;
    border: 1px solid #f0d8a8;
    border-radius: 11px;
    display: flex;
    align-items: flex-start;
    gap: 8px;
    color: #7b5615;
    background: #fff9eb;
}

.workspace-alert.neutral {
    border-color: #d9e0ed;
    color: #45546d;
    background: #f5f7fb;
}

.workspace-alert .material-icons {
    font-size: 16px;
}

.workspace-alert p {
    margin: 0;
    font-size: 8.5px;
    line-height: 1.8;
}

.workspace-save {
    min-height: 42px;
    border: 0;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    color: #fff;
    background: var(--brand);
    cursor: pointer;
    font-family: inherit;
    font-size: 10px;
    font-weight: 900;
    transition: background .2s ease, box-shadow .2s ease;
}

.workspace-save:hover {
    background: var(--brand-strong);
    box-shadow: 0 8px 20px color-mix(in srgb, var(--brand) 24%, transparent);
}

.workspace-save .material-icons {
    font-size: 17px;
}

@media (max-width: 1024px) {
    .start-body .visit-start-shell {
        padding: 32px;
        justify-content: flex-start;
    }

    .start-body .visit-start-hero {
        max-width: 720px;
        margin: 0 auto;
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .start-body .start-copy {
        text-align: right;
    }

    .start-body .start-copy .brand-logo {
        margin-bottom: 26px;
    }

    .start-body .start-copy h1 {
        max-width: 680px;
        font-size: clamp(2.8rem, 8vw, 4.8rem);
    }

    .start-body .start-copy .lead-text {
        margin: 0;
    }

    .start-body .trust-row {
        justify-content: flex-start;
    }

    .start-visual {
        max-width: 620px;
    }
}

@media (max-width: 620px) {
    .start-body .visit-start-shell {
        padding: 18px 14px 30px;
    }

    .start-body .start-copy .brand-logo {
        width: 82px;
        margin-bottom: 20px;
    }

    .start-body .start-copy .eyebrow {
        font-size: 10px;
    }

    .start-body .start-copy h1 {
        margin-bottom: 16px;
        font-size: clamp(2.35rem, 12vw, 3.25rem);
    }

    .start-body .start-copy .lead-text {
        font-size: 13px;
        line-height: 1.9;
    }

    .start-body .trust-row {
        margin-top: 20px;
        gap: 8px 14px;
    }

    .start-visual {
        margin-top: 22px;
    }

    .start-visual img {
        height: 180px;
    }

    .start-body .start-panel {
        min-height: 0;
        padding: 18px;
        border-radius: 18px;
    }

    .start-body .start-panel > .panel-heading {
        margin-bottom: 20px;
        padding-bottom: 16px;
        grid-template-columns: 40px minmax(0, 1fr) auto;
    }

    .start-body .start-panel .panel-icon {
        width: 38px;
        height: 38px;
    }

    .start-body .meeting-type-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .start-body .meeting-type-card:last-child {
        grid-column: 1 / -1;
    }

    .start-body .meeting-type-card > span {
        min-height: 82px;
    }

    .type-preview {
        grid-template-columns: 34px minmax(0, 1fr);
        padding: 14px;
    }

    .type-preview > .material-icons {
        width: 34px;
        height: 34px;
    }

    .start-body #meetingDetailsStep {
        grid-template-columns: 1fr;
    }

    .start-body #meetingDetailsStep > * {
        grid-column: 1 !important;
    }

    .start-body #meetingDetailsStep .form-actions {
        grid-template-columns: 1fr;
    }

    .start-body .start-dock {
        display: none;
    }
}
