/* Headset test: the softphone's look (softphone.scss tokens), standalone. */

@font-face { font-family: "Emorise Plus Jakarta Sans"; src: url("fonts/PlusJakartaSans-Regular.ttf") format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Emorise Plus Jakarta Sans"; src: url("fonts/PlusJakartaSans-Medium.ttf") format("truetype"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Emorise Plus Jakarta Sans"; src: url("fonts/PlusJakartaSans-SemiBold.ttf") format("truetype"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Emorise Plus Jakarta Sans"; src: url("fonts/PlusJakartaSans-Bold.ttf") format("truetype"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Emorise Plus Jakarta Sans"; src: url("fonts/PlusJakartaSans-ExtraBold.ttf") format("truetype"); font-weight: 800; font-display: swap; }
@font-face { font-family: "Emorise Instrument Sans"; src: url("fonts/InstrumentSans-Regular.ttf") format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Emorise Instrument Sans"; src: url("fonts/InstrumentSans-Medium.ttf") format("truetype"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Emorise Instrument Sans"; src: url("fonts/InstrumentSans-SemiBold.ttf") format("truetype"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Emorise Instrument Sans"; src: url("fonts/InstrumentSans-Bold.ttf") format("truetype"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Emorise Material Icons"; src: url("fonts/MaterialIcons.ttf") format("truetype"); font-weight: 400; font-display: block; }

:root {
    --brand: #6c5ce7;
    --brand-dark: #5d4ed5;
    --brand-light: #eeebfc;
    --brand-bright: #7d6ee8;
    --accent: #00b4d8;
    --mint: #80ffdb;
    --ink: #060608;
    --success: #1a9f7a;
    --success-light: #e3f5ef;
    --danger: #e14343;
    --danger-hover: #c93535;
    --danger-light: #fce8e8;
    --warning: #d99400;
    --warning-light: #fbf1dc;
    --info: #007c96;
    --info-light: #def1f5;
    --text: #060608;
    --text-secondary: rgba(6, 6, 8, 0.62);
    --text-muted: rgba(6, 6, 8, 0.42);
    --bg: #f7f5f1;
    --bg-tertiary: #eceae6;
    --border: rgba(6, 6, 8, 0.08);
    --border-medium: rgba(6, 6, 8, 0.14);
    --shadow-md: 0 4px 16px rgba(6, 6, 8, 0.07);
    --focus: 0 0 0 3px rgba(108, 92, 231, 0.18);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --font-display: "Emorise Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-body: "Emorise Instrument Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-body);
    font-size: 15px;
    line-height: 1.5;
}

h1, h2, h3 { font-family: var(--font-display); letter-spacing: -0.3px; margin: 0; }
h3 { font-size: 14px; font-weight: 700; margin: 16px 0 8px; }
p { margin: 0 0 12px; }

/* Material icons: <i class="o_mi o_mi_mic">, codepoints as in softphone.scss. */
.o_mi {
    display: inline-block;
    font-family: "Emorise Material Icons";
    font-style: normal;
    font-weight: normal;
    font-size: 18px;
    line-height: 1;
    letter-spacing: normal;
    text-transform: none;
    white-space: nowrap;
    vertical-align: -0.2em;
    -webkit-font-smoothing: antialiased;
}
.o_mi_headset_mic::before { content: "\e311"; }
.o_mi_mic::before { content: "\e029"; }
.o_mi_play_arrow::before { content: "\e037"; }
.o_mi_stop::before { content: "\e047"; }
.o_mi_check::before { content: "\e5ca"; }
.o_mi_close::before { content: "\e5cd"; }
.o_mi_warning::before { content: "\e002"; }
.o_mi_error::before { content: "\e000"; }
.o_mi_check_circle::before { content: "\e86c"; }
.o_mi_info::before { content: "\e88e"; }
.o_mi_phone::before { content: "\e0cd"; }
.o_mi_call::before { content: "\e0b0"; }
.o_mi_call_end::before { content: "\e0b1"; }
.o_mi_phone_in_talk::before { content: "\e61d"; }
.o_mi_ring_volume::before { content: "\e0d1"; }
.o_mi_volume_up::before { content: "\e050"; }
.o_mi_content_copy::before { content: "\e14d"; }
.o_mi_file_download::before { content: "\e2c4"; }
.o_mi_record_voice_over::before { content: "\e91f"; }
.o_mi_lock::before { content: "\e897"; }
.o_mi_usb::before { content: "\e1e0"; }
.o_mi_bluetooth::before { content: "\e1a7"; }
.o_mi_laptop::before { content: "\e31e"; }
.o_mi_hearing::before { content: "\e023"; }

/* Header: the softphone panel's gradient. */
.ht_header {
    background: linear-gradient(120deg, var(--brand-bright) 0%, var(--brand) 55%, var(--accent) 140%);
    color: #fff;
    padding: 28px 20px 64px;
}
.ht_header_inner {
    max-width: 820px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}
.ht_logo {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.18);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.ht_logo .o_mi { font-size: 28px; }
.ht_title { flex: 1 1 260px; }
.ht_title h1 { font-size: 26px; font-weight: 800; }
.ht_title p { margin: 2px 0 0; opacity: 0.9; }
.ht_privacy {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 13px;
}
.ht_privacy .o_mi { color: var(--mint); font-size: 16px; }

.ht_main {
    max-width: 820px;
    margin: -40px auto 0;
    padding: 0 16px 40px;
}

.ht_intro, .ht_card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    padding: 20px 24px;
    margin-bottom: 16px;
}
.ht_intro { display: flex; flex-direction: column; gap: 4px; }
.ht_card_key { border: 2px solid var(--brand); }

.ht_card_head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}
.ht_card_head h2 { font-size: 18px; font-weight: 700; flex: 1; }
.ht_step {
    width: 30px;
    height: 30px;
    flex-shrink: 0;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--brand), var(--brand-dark));
    color: #fff;
    font-family: var(--font-display);
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.ht_pill {
    font-family: var(--font-display);
    font-size: 12px;
    font-weight: 700;
    border-radius: 999px;
    padding: 3px 10px;
}
.ht_pill:empty { display: none; }
.ht_pill.is-yes { background: var(--success-light); color: var(--success); }
.ht_pill.is-no { background: var(--danger-light); color: var(--danger); }
.ht_pill.is-info { background: var(--brand-light); color: var(--brand-dark); }

/* Buttons */
.ht_actions { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; }
.ht_btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 16px;
    border-radius: var(--radius-md);
    border: 1.5px solid var(--border-medium);
    background: #fff;
    color: var(--text);
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}
.ht_btn:hover:not(:disabled) { border-color: var(--brand); }
.ht_btn:focus-visible { outline: none; box-shadow: var(--focus); }
.ht_btn:disabled { opacity: 0.45; cursor: not-allowed; }
.ht_btn_primary {
    border-color: transparent;
    background: linear-gradient(135deg, var(--brand), var(--brand-dark));
    color: #fff;
}
.ht_btn_primary:hover:not(:disabled) { border-color: transparent; filter: brightness(1.08); }
.ht_btn_danger { border-color: transparent; background: var(--danger); color: #fff; }
.ht_btn_danger:hover:not(:disabled) { border-color: transparent; background: var(--danger-hover); }
.ht_btn_yes.is-selected { background: var(--success); border-color: var(--success); color: #fff; }
.ht_btn_no.is-selected { background: var(--danger); border-color: var(--danger); color: #fff; }

.ht_segmented {
    display: inline-flex;
    border: 1.5px solid var(--border-medium);
    border-radius: var(--radius-md);
    overflow: hidden;
}
.ht_segmented button {
    border: 0;
    background: #fff;
    padding: 7px 14px;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    color: var(--text-secondary);
}
.ht_segmented button[aria-checked="true"] { background: var(--brand); color: #fff; }

/* Form fields */
.ht_field { display: flex; flex-direction: column; gap: 4px; font-size: 13px; font-weight: 600; color: var(--text-secondary); }
.ht_field.ht_inline { flex-direction: row; align-items: center; gap: 12px; }
.ht_field select {
    width: 100%;
    padding: 10px 12px;
    font: inherit;
    font-weight: 500;
    font-size: 14px;
    color: var(--text);
    background: #fff;
    border: 1.5px solid var(--border-medium);
    border-radius: var(--radius-md);
}
.ht_field select:focus { outline: none; border-color: var(--brand); box-shadow: var(--focus); }
.ht_check { display: flex; align-items: flex-start; gap: 8px; margin: 8px 0; cursor: pointer; }
.ht_check input { margin-top: 4px; accent-color: var(--brand); }
.ht_grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 12px 0 4px; }
.ht_hint { color: var(--text-muted); font-size: 13px; }
.ht_status { color: var(--text-secondary); font-size: 14px; min-height: 1.5em; margin: 4px 0 8px; }
.ht_status.is-error { color: var(--danger); }
.ht_status.is-ok { color: var(--success); }

/* Alerts */
.ht_alert {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    padding: 12px 14px;
    border-radius: var(--radius-md);
    margin: 0 0 16px;
    font-size: 14px;
}
.ht_alert .o_mi { font-size: 20px; flex-shrink: 0; }
.ht_alert ul { margin: 4px 0 0; padding-left: 18px; }
.ht_alert_warn { background: var(--warning-light); color: #6b4a00; }
.ht_alert_warn .o_mi { color: var(--warning); }
.ht_alert_error { background: var(--danger-light); color: var(--danger-hover); }

/* Devices */
.ht_pick {
    background: linear-gradient(135deg, rgba(108, 92, 231, 0.12), rgba(108, 92, 231, 0.03));
    border-radius: var(--radius-md);
    padding: 12px 14px;
    font-size: 14px;
}
.ht_pick strong { font-family: var(--font-display); }
.ht_pick p { margin: 0 0 4px; }
.ht_pick p:last-child { margin: 0; }
.ht_devices { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.ht_devices li {
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 8px 10px;
    font-size: 14px;
}
.ht_devices .ht_dev_name { font-weight: 600; }
.ht_devices .ht_dev_label { color: var(--text-muted); font-size: 12px; word-break: break-word; }
.ht_badges { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 4px; }
.ht_badge {
    font-family: var(--font-display);
    font-size: 11px;
    font-weight: 700;
    border-radius: 999px;
    padding: 1px 8px;
    background: var(--bg-tertiary);
    color: var(--text-secondary);
}
.ht_badge.is-headset { background: var(--brand-light); color: var(--brand-dark); }
.ht_badge.is-builtin { background: var(--info-light); color: var(--info); }
.ht_badge.is-pick { background: var(--brand); color: #fff; }
.ht_badge.is-role { background: var(--success-light); color: var(--success); }

/* Live call numbers */
.ht_live { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 8px 0 12px; }
.ht_tile {
    border-radius: var(--radius-md);
    background: var(--bg);
    padding: 10px 12px;
}
.ht_tile_value { font-family: var(--font-display); font-weight: 800; font-size: 20px; }
.ht_tile_label { font-size: 12px; color: var(--text-secondary); line-height: 1.3; }
.ht_tile.is-ok .ht_tile_value { color: var(--success); }
.ht_tile.is-bad .ht_tile_value { color: var(--danger); }

.ht_findings { list-style: none; padding: 0; margin: 0 0 12px; display: flex; flex-direction: column; gap: 6px; }
.ht_findings li { display: flex; gap: 8px; align-items: flex-start; font-size: 14px; }
.ht_findings .is-ok .o_mi { color: var(--success); }
.ht_findings .is-warn .o_mi { color: var(--warning); }
.ht_findings .is-error .o_mi { color: var(--danger); }

.ht_details { margin: 8px 0 12px; font-size: 13px; }
.ht_details summary { cursor: pointer; color: var(--brand-dark); font-weight: 600; }
.ht_details pre, .ht_details table { margin-top: 8px; }
.ht_details pre {
    max-height: 320px;
    overflow: auto;
    background: var(--bg);
    border-radius: var(--radius-sm);
    padding: 10px;
    font-family: var(--font-mono);
    font-size: 12px;
    white-space: pre-wrap;
    word-break: break-word;
}
.ht_details table { border-collapse: collapse; width: 100%; font-family: var(--font-mono); font-size: 12px; }
.ht_details td { padding: 3px 8px; border-bottom: 1px solid var(--border); vertical-align: top; overflow-wrap: anywhere; }
.ht_details td:first-child { color: var(--text-secondary); width: 40%; }

/* Answers */
.ht_answer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    border-top: 1px solid var(--border);
    padding-top: 14px;
    margin-top: 8px;
}
.ht_answer > span { font-family: var(--font-display); font-weight: 700; flex: 1 1 100%; }

.ht_explain { margin-top: 16px; background: var(--bg); border-radius: var(--radius-md); padding: 12px 16px; font-size: 14px; }
.ht_explain h3 { margin-top: 0; }
.ht_explain ul { margin: 0 0 8px; padding-left: 18px; }
.ht_conclusion { font-weight: 600; margin: 0; }
.ht_conclusion:empty { display: none; }
#report-conclusion {
    background: var(--brand-light);
    color: var(--brand-dark);
    border-radius: var(--radius-md);
    padding: 12px 14px;
    margin-bottom: 12px;
}

.ht_hook { display: flex; align-items: center; gap: 10px; font-weight: 600; margin: 8px 0; }
.ht_hook_dot { width: 14px; height: 14px; border-radius: 50%; background: var(--bg-tertiary); border: 2px solid var(--border-medium); }
.ht_hook_dot.is-off { background: var(--success); border-color: var(--success); }
.ht_log { margin: 8px 0; padding-left: 20px; font-size: 13px; color: var(--text-secondary); max-height: 160px; overflow: auto; }

.ht_summary { list-style: none; padding: 0; margin: 0 0 8px; display: grid; grid-template-columns: 1fr 1fr; gap: 6px 16px; font-size: 14px; }
.ht_summary li { display: flex; justify-content: space-between; border-bottom: 1px solid var(--border); padding: 4px 0; }
.ht_summary .is-yes { color: var(--success); font-weight: 700; }
.ht_summary .is-no { color: var(--danger); font-weight: 700; }
.ht_summary .is-none { color: var(--text-muted); }

.ht_footer { text-align: center; color: var(--text-muted); font-size: 12px; padding: 0 0 32px; }
.ht_footer a { color: inherit; }
.ht_sentence { margin-top: 8px; font-style: italic; }

@media (max-width: 640px) {
    .ht_header { padding: 20px 16px 56px; }
    .ht_intro, .ht_card { padding: 16px; }
    .ht_grid2, .ht_summary { grid-template-columns: 1fr; }
    .ht_live { grid-template-columns: repeat(2, 1fr); }
    .ht_field.ht_inline { flex-direction: column; align-items: flex-start; }
}
