* {
    box-sizing: border-box;
}

:root {
    color-scheme: dark;
    font-family: Arial, Helvetica, sans-serif;
    color: #f5f5f6;
    background: #111315;
}

[hidden] {
    display: none !important;
}

label {
    display: block;
    font-size: 16px;
    line-height: 1.4;
    margin-bottom: 7px;
}

.portal_input, .portal_select, .portal_textarea {
    display: block;
    width: 100%;
    border: 1px solid #454d55;
    border-radius: 8px;
    background: #191a1aa6;
    color: #f5f5f6;
    padding: 14px 20px;
    font: inherit;
    font-size: 16px;
    box-shadow: inset 0 1px 3px #0002;
}

.portal_select option {
    background: #252b31;
}

.portal_textarea {
    resize: vertical;
    min-height: 150px;
}

.portal_input:disabled, .portal_select:disabled {
    opacity: 1;
    color: #a5afba;
    background: #343d47;
    border-color: #4b5662;
    cursor: default;
}

.form_grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 26px;
}

.form_columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
}

.form_field {
    margin-bottom: 18px;
    min-width: 0;
}

.form_section {
    min-width: 0;
    border: 0;
    padding: 0;
    margin: 0;
}

.form_grid>.form_section+.form_section {
    border-left: 1px solid #ffffff20;
    padding-left: 26px;
}

.form_section legend {
    font-size: 16px;
    margin-bottom: 7px;
}

fieldset.form_field {
    margin-bottom: 18px;
}

.form_section h2 {
    font-size: 18px;
    margin: 0 0 18px;
}

.form_hint {
    font-size: 13px;
    color: #aeb8c5;
    line-height: 1.5;
    margin: 7px 0 0;
}

.form_actions, .form_toolbar, .section_tabs, .profile_summary {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}

.form_actions {
    border-top: 1px solid #ffffff25;
    padding-top: 20px;
    margin-top: 22px;
    justify-content: flex-end;
}

.form_actions .action_start {
    margin-right: auto;
}

.form_action_group {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px;
    max-width: 100%;
}

.form_submit_actions {
    justify-content: flex-end;
    gap: 20px;
}

.form_submit_actions .form_checkbox {
    margin: 0;
}

.form_toolbar {
    justify-content: space-between;
    margin: 20px 0;
    margin-top: 0px;
}

.form_toolbar .portal_input, .form_toolbar .portal_select {
    width: auto;
    padding: 11px 13px;
    min-height: 44px;
}

.form_toolbar>label:not(.visually_hidden) {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
}

.form_choices {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.form_choices label {
    display: flex;
    align-items: center;
    gap: 11px;
    flex: 1;
    margin: 0;
    padding: 13px 15px;
    font-size: 14px;
    cursor: pointer;
    border: 1px solid #454d55;
    border-radius: 9px;
    background: #30363d;
    box-shadow: inset 0 1px 1px #ffffff12, 0 2px 3px #0003;
    transition: background .18s, box-shadow .18s;
}

.form_choices label:has(input:checked) {
    background: #272f37;
    border-color: #647a8d;
    box-shadow: inset 0 2px 4px #0006;
}

.form_choices label:has(input:disabled) {
    opacity: .65;
    cursor: default;
}

.form_choices input {
    appearance: none;
    flex: 0 0 18px;
    width: 18px;
    height: 18px;
    margin: 0;
    border: 1px solid #171d23;
    border-radius: 50%;
    background: #30363d;
    box-shadow: inset 0 1px 3px #0009, 0 1px 0 #ffffff15;
    display: grid;
    place-content: center;
}

.form_choices input::after {
    content: '';
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #8cc8ed;
    transform: scale(0);
    transition: transform .18s;
}

.form_choices input:checked::after {
    transform: scale(1);
}

.profile_summary {
    padding: 22px 0;
    border-bottom: 1px solid #ffffff25;
    margin-bottom: 24px;
}

.profile_avatar {
    display: grid;
    place-items: center;
    width: 72px;
    height: 72px;
    border-radius: 50%;
    border: 1px solid #737e89;
    background: #ffffff0a;
    font-size: 25px;
}

.profile_summary h2 {
    margin: 0 0 7px;
    font-size: 21px;
}

.portal_badge {
    display: inline-block;
    border: 1px solid #587b98;
    background: #3188c51a;
    color: #a6d4f5;
    border-radius: 4px;
    padding: 4px 9px;
    font-size: 12px;
}

.portal_dialog {
    width: min(500px, calc(100% - 32px));
    padding: 25px;
    background: #252b31;
    color: #edf0f4;
    border: 1px solid #66717d;
    border-radius: 10px;
}

.portal_dialog::backdrop {
    background: #000a;
}

.message.message_success {
    color: #b6e2c2;
    border-color: #558866;
    background: #34734922;
}

.portal_table {
    color: #edf0f4;
    border: 1px solid #424950;
    border-radius: 6px;
    width: 100%;
}

.portal_table thead {
    background: #191a1aa6;
}

.portal_table th, .portal_table td {
    padding: 15px 18px !important;
    border-bottom: 1px solid #ffffff12;
    vertical-align: middle;
}

.portal_table th {
    font-size: 14px;
    white-space: nowrap;
}

.portal_table td {
    font-size: 15px;
}

.table_scroll {
    overflow-x: auto;
}

.dt-container .dt-info {
    color: #afb8c3;
    font-size: 14px;
}

.dt-container .dt-paging-button {
    color: #dce5ef !important;
    border-radius: 5px;
}

.dt-container .dt-paging-button.current {
    background: #246fa6 !important;
    border-color: #4195d3 !important;
}

@media (max-width: 700px) {
    .form_grid, .form_columns {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .form_grid>.form_section+.form_section {
        border-left: 0;
        border-top: 1px solid #ffffff20;
        padding: 20px 0 0;
    }

    .form_toolbar {
        align-items: stretch;
    }

    .form_toolbar .portal_input {
        width: 100%;
    }
}

input::placeholder {
    color: #90959d;
    opacity: 1;
}

button {
    font: inherit;
    cursor: pointer;
}

a {
    color: #8dd1ff;
    text-underline-offset: 3px;
}

a:hover {
    color: #c5e9ff;
    text-decoration: underline;
}

.primary_button {
    width: 100%;
    min-height: 57px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 13px;
    border: 1px solid #4195d3;
    border-radius: 8px;
    background: linear-gradient(#287fbd, #206ba3);
    color: white;
    font-size: 20px;
    font-weight: 600;
    box-shadow: inset 0 1px 0 #ffffff20;
}

.primary_button:hover {
    background: #328dcc;
}

button:disabled {
    opacity: .65;
    cursor: wait;
}

:focus-visible {
    outline: 3px solid #8dd1ff;
    outline-offset: 4px;
}

.portal_input:focus, .portal_select:focus, .portal_textarea:focus, .form_choices input:focus-visible, .form_checkbox input:focus-visible {
    outline: none;
    border-color: #8b949c;
    box-shadow: none;
}

.message {
    color: #ffb6b8;
    font-size: 15px;
    line-height: 1.5;
    margin: 0 0 18px;
}

.message:not([hidden]) {
    padding: 12px 15px;
    border: 1px solid #e45b6266;
    border-radius: 8px;
    background: #b529321a;
}

.field_error {
    margin: 8px 0 0;
    color: #ffb6b8;
    font-size: 13px;
    line-height: 1.4;
}

.portal_input[aria-invalid='true'], .portal_select[aria-invalid='true'], .portal_textarea[aria-invalid='true'] {
    border-color: #f17d84;
    box-shadow: 0 0 0 3px #ef555515;
}

.portal_panel {
    border: 1px solid #3e444a;

    background: linear-gradient(130deg, #1e2023f0, rgb(42 45 49 / 79%) 44%, #1e2023f0);
    box-shadow: inset 0 1px 0 #ffffff15, 0 24px 70px #0007
}

body {
    margin: 0;
    min-height: 100vh;
    background: #111315 url('/images/bg_dark.png') center / cover fixed no-repeat;
}

.tickets_heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.ticket_action {
    width: auto;
    min-height: 44px;
    padding: 10px 18px;
    font-size: 16px;
    text-decoration: none;
}

.ticket_action:hover {
    color: white;
    text-decoration: none;
}

.tickets_scope {
    margin: 0 0 20px;
    color: #aeb8c5;
    font-size: 13px;
}

.tickets_toolbar, .tickets_filters {
    display: flex;
    align-items: center;
    gap: 14px;
}

.tickets_toolbar {
    justify-content: space-between;
    margin-bottom: 18px;
}

.tickets_length_label {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    white-space: nowrap;
}

#tickets_search {
    width: min(310px, 100%);
}

.tickets_table_scroll {
    overflow-x: auto;
}

#tickets_table, #billing_table {
    --dt-row_background-hover: 255, 255, 255;
    --dt-row_background-stripe: 255, 255, 255;
    color: #edf0f4;
    border: 1px solid #424950;
    border-radius: 6px;
}

#billing_results .tickets_toolbar, #billing_results .tickets_filters {
    flex-wrap: wrap;
}

#billing_table th, #billing_table td {
    white-space: nowrap;
}

#billing_table td.invoice_child { white-space: normal; padding: 0; }
.billing_open { border: 0; background: transparent; color: #8dd1ff; cursor: pointer; font: inherit; }
.billing_open[aria-expanded="true"] i { display: inline-block; transform: rotate(180deg); }
.invoice_panel { padding: 20px; overflow: hidden; background: #191d21; white-space: normal; }
.invoice_panel h2 { font-size: 18px; margin: 0 0 14px; }
.invoice_controls { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 12px; }
.invoice_viewer { width: 100%; height: 70vh; min-height: 420px; border: 1px solid #56616b; background: #fff; }

#billing_table th.billing_center, #billing_table td.billing_center {
    text-align: center;
}

#billing_table input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #3087b5;
}

.ticket_subject a {
    color: #eef1f5;
    font-weight: 500;
    text-decoration: none;
    overflow-wrap: anywhere;
}

.ticket_subject a:hover {
    color: #8dd1ff;
    text-decoration: underline;
}

.ticket_task {
    margin: 5px 0 0;
    font-size: 14px;
    line-height: 1.5;
    color: #bdc0c5;
    overflow-wrap: anywhere;
}

.ticket_status {
    display: inline-block;
    background: #4679a52b;
    border: 1px solid #5c7791;
    border-radius: 5px;
    padding: 6px 12px;
    font-size: 13px;
    text-align: center;
    min-width: 90px;
}

.visually_hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

@media (max-width: 700px) {
    .tickets_toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .tickets_filters {
        flex-wrap: wrap;
    }

    #tickets_search {
        width: 100%;
    }

    #tickets_status {
        flex: 1;
    }

    .tickets_heading {
        align-items: flex-start;
    }

    .ticket_action {
        font-size: 14px;
        padding-inline: 12px;
        white-space: nowrap;
    }
}

/* Shared action buttons. The login button keeps its larger layout above. */
.portal_button {
    position: relative;
    width: auto;
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    padding: 10px 18px;
    font-size: 15px;
    line-height: 20px;
    font-weight: 500;
    gap: 0;
    border: 1px solid #596571;
    border-radius: 6px;
    background: #3b4651;
    color: white;
    text-decoration: none;
    overflow: hidden;
}

.portal_button:hover {
    background: #4c5966;
    color: white;
    text-decoration: none;
}

.portal_button.primary_button {
    background: #2579b2;
    border-color: #4195d3;
}

.portal_button.primary_button:hover {
    background: #328dcc;
}

.portal_button.danger_button {
    background: #a93740;
    border-color: #c04a53;
}

.portal_button.danger_button:hover {
    background: #c0444e;
}

.portal_button.btn-label {
    padding-left: 54px;
}

.portal_button.btn-label .label-icon {
    position: absolute;
    display: flex;
    align-items: center;
    justify-content: center;
    left: 0;
    top: 0;
    bottom: 0;
    width: 38px;
    background: #ffffff18;
    font-size: 16px;
    line-height: 1;
}

.portal_button.portal_button_sm {
    min-height: 0;
    padding: 6px 12px;
    font-size: 13px;
    line-height: 18px;
}

.portal_button.portal_button_sm.btn-label {
    padding-left: 42px;
}

.portal_button.portal_button_sm.btn-label .label-icon {
    width: 30px;
    font-size: 14px;
}

.form_actions .portal_button:disabled {
    cursor: not-allowed;
}

.page_heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.locked_control {
    position: relative;
}

.locked_control .portal_input {
    padding-right: 45px;
}

.locked_control>i {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #a5afba;
    pointer-events: none;
}

.portal_select {
    appearance: none;
    padding-right: 42px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='m1 1 5 5 5-5' fill='none' stroke='%23b4c0cb' stroke-width='1.5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
}

.form_toolbar .portal_select {
    padding-right: 38px;
}

.portal_dropdown {
    position: relative;
    min-width: 0;
}

.portal_dropdown::before {
    content: '';
    position: absolute;
    inset: -6px;
    border-radius: 10px 10px 0 0;
    background: #4b535c;
    opacity: 0;
    transition: opacity .16s;
    pointer-events: none;
}

.portal_dropdown.is_open {
    z-index: 8;
}

.portal_dropdown.is_open::before {
    opacity: 1;
}

.dropdown_trigger {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
    text-align: left;
    position: relative;
    z-index: 1;
    padding-right: 16px;
    background-image: none;
}

.dropdown_trigger>span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dropdown_trigger>i {
    font-size: 12px;
    flex-shrink: 0;
    transition: transform .18s;
}

.portal_dropdown.is_open > .dropdown_trigger > i {
    transform: rotate(180deg);
}

.dropdown_panel {
    position: absolute;
    top: calc(100% - 1px);
    left: -6px;
    right: -6px;
    padding: 8px 6px 6px;
    background: #4b535c;
    border-radius: 0 0 10px 10px;
    box-shadow: 0 12px 18px #0006;
    max-height: 240px;
    overflow-y: auto;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity .18s, transform .18s, visibility .18s;
}

.portal_dropdown.is_open > .dropdown_panel {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown_option {
    padding: 11px 14px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 15px;
    color: #f0f3f6;
}

.dropdown_option:hover, .dropdown_option.option_active {
    background: #303942;
}

.dropdown_option[aria-selected='true'] {
    color: #b6ddf6;
    background: #34424e;
}

.portal_table .clickable_row {
    cursor: pointer;
}

.portal_table .clickable_row:focus-visible {
    outline-offset: -3px;
}

.portal_table .clickable_row:hover {
    background: #ffffff0a;
}

/* TinyMCE 4's bundled skin shares the portal palette. */
.mce-tinymce, .mce-panel {
    background: #242424 !important;
    border-color: #494949 !important;
}

.mce-toolbar-grp, .mce-statusbar {
    background: #242424 !important;
}

.mce-btn {
    background: transparent !important;
    border-color: transparent !important;
}

.mce-btn:hover, .mce-btn.mce-active {
    background: #3b3b3b !important;
}

.mce-btn button, .mce-ico, .mce-label, .mce-statusbar .mce-path-item {
    color: #e5e5e5 !important;
    text-shadow: none !important;
}

.mce-window .mce-textbox {
    background: #191919;
    color: #ededed;
    border-color: #494949;
}

@media (prefers-reduced-motion: reduce) {
    .dropdown_panel, .portal_dropdown::before, .dropdown_trigger>i, .form_choices label, .form_choices input::after {
        transition: none;
    }
}

.password_control {
    position: relative;
}

.password_entry {
    position: relative;
}

.password_entry .portal_input {
    padding-right: 90px;
}

.password_entry input::-ms-reveal, .password_entry input::-ms-clear {
    display: none;
}

.password_reveal {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    width: 38px;
    height: 36px;
    border: 0;
    border-radius: 5px;
    background: transparent;
    color: #b9c8d5;
    font-size: 18px;
}

.password_reveal:hover {
    background: #ffffff10;
    color: white;
}

.password_tools {
    display: flex;
    gap: 14px;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 10px;
}

.password_requirements {
    position: absolute;
    right: 46px;
    top: 50%;
    transform: translateY(-50%);
    width: 38px;
    height: 36px;
    border: 0;
    border-radius: 5px;
    background: transparent;
    color: #aacee7;
    font-size: 18px;
    padding: 0;
}

.password_requirements:hover {
    background: #ffffff10;
    color: white;
}

.password_panel {
    position: absolute;
    z-index: 12;
    bottom: calc(100% + 12px);
    right: 0;
    width: min(310px, 100%);
    padding: 18px;
    background: #252e37;
    border: 1px solid #586a79;
    border-radius: 10px;
    box-shadow: 0 14px 35px #0009;
}

.password_panel::before {
    content: '';
    position: absolute;
    bottom: -6px;
    right: 59px;
    width: 10px;
    height: 10px;
    background: #252e37;
    border-right: 1px solid #586a79;
    border-bottom: 1px solid #586a79;
    transform: rotate(45deg);
}

.password_panel strong {
    font-size: 14px;
}

.password_panel p {
    margin: 6px 0 13px;
    color: #aebccb;
    font-size: 12px;
}

.password_checklist {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 11px;
}

.password_checklist li {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    color: #c5ced8;
}

.password_checklist [role='checkbox'] {
    display: grid;
    place-items: center;
    width: 18px;
    height: 18px;
    border: 1px solid #63717e;
    border-radius: 4px;
    color: transparent;
    transition: color .15s, background .15s;
}

.password_checklist [aria-checked='true'] {
    color: #d9f0ff;
    background: #267dae;
    border-color: #5ba6d0;
}

.form_hint.password_valid {
    color: #9bd5b4;
}

#shell_main:has(> #shell_loading:not([hidden])), .section_content:has(> .loader_area:not([hidden])) {
    display: flex;
    flex-direction: column;
}

.loader_area {
    display: flex;
    flex: 1;
    justify-content: center;
    align-items: center;
    min-height: 280px;
}

.standard_loader {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

.standard_loader_container {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
}

.standard_loader_logo {
    position: relative;
    width: 36px;
    height: 36px;
    background: url('/images/loader_2021_white.png') center / contain no-repeat;
}

.standard_loader_wheel {
    position: absolute;
    inset: 3px;
    border: 3px solid #cc0808;
    border-left-color: transparent;
    border-right-color: transparent;
    border-radius: 50%;
    animation: standard_loader_spin 725ms linear infinite;
}

.standard_loader_text {
    margin-top: 15px;
    color: #acbac7;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
}

.standard_loader_inline {
    display: inline-flex;
    flex-direction: row;
    gap: 8px;
    padding: 0;
}

.standard_loader_inline .standard_loader_container {
    width: 24px;
    height: 24px;
}

.standard_loader_inline .standard_loader_logo {
    width: 14px;
    height: 14px;
}

.standard_loader_inline .standard_loader_wheel {
    inset: 1px;
    border-width: 2px;
}

.standard_loader_inline .standard_loader_text {
    margin: 0;
    font-size: inherit;
    color: inherit;
}

@keyframes standard_loader_spin {
    to {
        transform: rotate(360deg);
    }
}

@media (prefers-reduced-motion: reduce) {
    .standard_loader_wheel {
        animation: none;
    }

    .password_checklist [role='checkbox'] {
        transition: none;
    }
}

.form_checkbox {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 15px 0 0;
    font-size: 14px;
    cursor: pointer;
}

.form_checkbox input {
    appearance: none;
    display: grid;
    place-content: center;
    flex: 0 0 21px;
    width: 21px;
    height: 21px;
    margin: 0;
    border: 1px solid #63717e;
    border-radius: 5px;
    background: #14191d;
}

.form_checkbox input:checked {
    background: #267dae;
    border-color: #5ba6d0;
}

.form_checkbox input:checked::after {
    content: "";
    width: 6px;
    height: 11px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: translateY(-1px) rotate(45deg);
}

.profile_photo_control {
    position: relative;
    flex: 0 0 100px;
}

.profile_photo_control .profile_avatar {
    width: 100px;
    height: 100px;
    overflow: hidden;
}

.profile_photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile_camera {
    position: absolute;
    bottom: -2px;
    right: -2px;
    display: grid;
    place-items: center;
    width: 32px;
    height: 32px;
    padding: 0;
    border: 1px solid #8194a4;
    border-radius: 50%;
    background: #34414c;
    color: #f5f5f6;
    font-size: 16px;
}

.profile_camera:hover {
    background: #456075;
}

.profile_details {
    flex: 1;
    min-width: 0;
}

.profile_identity {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}

.profile_identity h2 {
    margin: 0;
}

.profile_photo_actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-top: 10px;
}

@media (max-width: 700px) {
    .profile_details {
        flex-basis: calc(100% - 114px);
    }
}

.form_label_row {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 4px 12px;
    margin-bottom: 7px;
}

.form_label_row label, .form_label_row .form_hint {
    margin: 0;
}

/* Ticket overview, activity cards and form previews share the portal controls. */
.ticket_overview {
    padding: 2px 0 24px;
    border-bottom: 1px solid #ffffff20;
}

.ticket_intro {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.ticket_intro h2 {
    font-size: 24px;
    line-height: 1.4;
    margin: 0;
    overflow-wrap: anywhere;
}

.ticket_facts {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 20px;
    margin-top: 14px;
    color: #bdc7d2;
    font-size: 14px;
}

.ticket_facts>span {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    min-width: 0;
    overflow-wrap: anywhere;
}

.ticket_facts i {
    color: #97a7b7;
}

.priority_badge {
    background: #3d4854;
    color: #e2e7ed;
    border-color: #637181;
}

.priority_badge[data-priority="critical"] {
    background: #a92d38;
    color: #fff;
    border-color: #c64b57;
}

.priority_badge[data-priority="high"] {
    background: #80542c;
    color: #fff0db;
    border-color: #a17845;
}

.priority_badge[data-priority="medium"] {
    background: #5b5733;
    color: #f0eac5;
    border-color: #898351;
}

.timeline_heading h2 {
    font-size: 19px;
    margin: 0;
}

.ticket_timeline {
    list-style: none;
    margin: 0;
    padding: 0;
}

.timeline_item {
    position: relative;
    padding: 0 0 24px 66px;
}

.timeline_item::before {
    content: '';
    position: absolute;
    left: 23px;
    top: 26px;
    bottom: -26px;
    width: 2px;
    background: #56616b;
}

.timeline_item:last-child::before {
    display: none;
}

.timeline_icon {
    position: absolute;
    top: 20px;
    left: 0;
    width: 48px;
    height: 48px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: #28597c;
    border: 4px solid #22282d;
    box-shadow: 0 0 0 1px #5a7082;
    color: #e3f3ff;
    font-size: 21px;
}

.timeline_icon::after {
    content: '';
    position: absolute;
    left: calc(100% + 4px);
    top: 50%;
    width: 20px;
    border-top: 1px dashed #808080;
}


.timeline_card {
    background: #161616;
    border: 1px solid #323438;
    border-radius: 9px;
    box-shadow: 0 5px 16px #0002;
    overflow: hidden;
}

.timeline_card_header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 17px 22px;
    border-bottom: 1px solid #ffffff16;
    background: #ffffff03;
}

.timeline_card_header h3 {
    font-size: 16px;
    margin: 0;
    background: #2a2d31d4;
}

.timeline_author_group {
    display: flex;
    align-items: center;
    gap: 12px;
}

.timeline_photo {
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    object-fit: cover;
    border-radius: 50%;
    border: 1px solid #677582;
}

.timeline_meta {
    display: flex;
    flex-direction: column;
    gap: 6px;
    text-align: right;
    font-size: 15px;
    color: #d4dee8;
}

.timeline_meta time {
    color: #b3c0ce;
    font-size: 14px;
}

.timeline_email_panel {
    margin-top: 16px;
    border-top: 1px solid #424950;
    padding-top: 12px;
}
.timeline_email_panel > summary { cursor: pointer; color: #8dd1ff; list-style: none; }
.timeline_email_panel > summary::-webkit-details-marker { display: none; }
.timeline_card_body .timeline_email_text { font-weight: 400; }
.timeline_email_text strong, .timeline_details strong { font-weight: 700; }
.timeline_email_panel > summary i { margin-left: 8px; }
.timeline_email_panel[open] > summary i { display: inline-block; transform: rotate(180deg); }
.timeline_email_body { white-space: pre-wrap; overflow-wrap: anywhere; overflow: hidden; margin-top: 12px; }
.timeline_labor { width: 100%; }
.timeline_task_columns { display: flex; flex-wrap: wrap; gap: 24px; }
.timeline_task_columns > section { flex: 1 1 240px; }
.timeline_task_columns ul { padding-left: 0; list-style: none; }
.timeline_task_columns li { margin-bottom: 8px; display: flex; gap: 8px; }
.task_completed { color: #4eba6e; }

.timeline_card_body {
    padding: 20px 22px;
    line-height: 1.65;
    overflow-wrap: anywhere;
}

.timeline_card_body h4 {
    margin: 0 0 12px;
    font-size: 16px;
}

.timeline_details {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 20px;
    margin-bottom: 12px;
    color: #fff;
    font-size: 14px;
}

.rich_content> :first-child {
    margin-top: 0;
}

.rich_content> :last-child {
    margin-bottom: 0;
}

.item_amount {
    font-size: 21px;
    color: #dcebe2;
}

.empty_state {
    text-align: center;
    padding: 45px 20px;
    color: #b5c0ca;
    border: 1px solid #404144;
    border-radius: 10px;
}

.action_menu {
    position: relative;
}

.action_menu summary {
    list-style: none;
    cursor: pointer;
}

.action_menu summary::-webkit-details-marker {
    display: none;
}

.action_menu_panel {
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    z-index: 20;
    min-width: 230px;
    padding: 6px;
    background: #343c44;
    border: 1px solid #606d79;
    border-radius: 8px;
    box-shadow: 0 10px 30px #0007;
}

.action_menu_panel button {
    display: block;
    width: 100%;
    border: 0;
    background: none;
    color: #e4eaf0;
    padding: 12px;
    text-align: left;
    border-radius: 5px;
    font: inherit;
    cursor: pointer;
}

.action_menu_panel button:hover, .action_menu_panel button:focus-visible {
    background: #ffffff15;
}

.preview_notice {
    background: #2874a31c;
    border: 1px solid #4a697f;
    border-radius: 8px;
    padding: 14px 18px;
    color: #b5d5ec;
    line-height: 1.5;
    margin: 0 0 24px;
}

.file_selection {
    border: 1px dashed #566677;
    border-radius: 9px;
    text-align: center;
    background: #14191d70;
    padding: 25px;
}

.file_selection>i {
    font-size: 30px;
    color: #92bddd;
}

.file_selection .portal_input {
    max-width: 560px;
    margin: auto;
}

.approval_summary {
    margin-top: 26px;
    padding: 18px;
    border: 1px solid #ffffff20;
    border-radius: 8px;
}

.approval_summary h2 {
    font-size: 16px;
    margin: 0 0 10px;
}

.approval_summary p {
    color: #b8c3ce;
    margin: 0;
}

@media (max-width: 700px) {
    .ticket_facts {
        gap: 18px;
    }

    .timeline_item {
        padding-left: 43px;
    }

    .timeline_icon {
        width: 32px;
        height: 32px;
        left: 0;
        font-size: 14px;
        border-width: 2px;
    }
    .timeline_icon::after { left: calc(100% + 2px); width: 11px; }

    .timeline_item::before {
        left: 15px;
    }

    .timeline_card_header {
        padding: 14px;
        align-items: flex-start;
    }

    .timeline_card_body {
        padding: 16px;
    }

    .timeline_meta {
        font-size: 14px;
    }

    .timeline_meta time {
        font-size: 13px;
    }

    .timeline_author_group {
        gap: 8px;
    }

    .timeline_card_header {
        flex-wrap: wrap;
    }
}

.dropdown_option.described_option {
    padding: 13px 15px;
    line-height: 1.4;
}

.described_option>span:first-child {
    display: block;
    font-weight: 600;
}

.dropdown_option_description {
    display: block;
    margin-top: 5px;
    font-size: 13px;
    color: #bfccd7;
    white-space: normal;
}

/* Feedback colors follow the shared visible-message rule. */
.message.message_success:not([hidden]) {
    color: #b6e2c2;
    border-color: #558866;
    background: #34734922;
}

.form_actions .message {
    margin: 0;
}

.summary_progress_circle {
    position: relative;
    width: 50px;
    height: 50px;
    flex: 0 0 50px;
}

.summary_progress_circle svg {
    transform: rotate(-90deg);
}

.progress_track {
    stroke: #0003;
}

.progress_ring {
    stroke: #477ed0;
    transition: stroke-dashoffset .5s ease-in-out;
}

.is_complete .progress_ring {
    stroke: #28a745;
}

.summary_progress_text {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    font-size: 13px;
    font-weight: bold;
    letter-spacing: -1px;
}

.ticket_action_panel {
    display: grid;
    grid-template-rows: 0fr;
    opacity: 0;
    visibility: hidden;
    transition: grid-template-rows .25s ease, opacity .25s ease, visibility .25s;
}

.ticket_action_panel.is_open {
    grid-template-rows: 1fr;
    opacity: 1;
    visibility: visible;
}

.ticket_action_inner {
    min-height: 0;
    overflow: hidden;
}

#ticket_action_form {
    padding: 22px;
    margin: 0 0 22px;
    border: 1px solid #52616e;
    border-radius: 9px;
    background: #18191acc;
}

#ticket_action_title {
    margin: 0 0 20px;
}

.file_selection[role='button'] {
    cursor: pointer;
}

.file_selection.is_dragging, .file_selection[role='button']:hover {
    border-color: #8dd1ff;
    background: #263643;
}

.profile_form .form_grid {
    grid-template-columns: 1fr;
}

.dashboard_stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 26px;
}

.dashboard_stat {
    padding: 24px 14px;
    text-align: center;
    border: 1px solid #46515d;
    border-radius: 9px;
    background: #1d1e20;
}

.dashboard_stat h2 {
    font-size: 14px;
    color: #b3d9f9;
    font-weight: normal;
    margin: 0 0 14px;
}

.dashboard_stat strong {
    font-size: 30px;
    font-weight: 500;
}

.dashboard_grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 210px;
    gap: 22px;
}

.dashboard_grid h2 {
    margin: 0 0 18px;
    font-size: 18px;
}

.dashboard_actions {
    padding: 20px;
    border: 1px solid #46515d;
    border-radius: 9px;
    align-self: start;
}

@media (max-width: 800px) {
    .dashboard_stats {
        grid-template-columns: repeat(2, 1fr);
    }

    .dashboard_grid {
        grid-template-columns: 1fr;
    }
}

@media (prefers-reduced-motion: reduce) {
    .ticket_action_panel, .progress_ring {
        transition: none;
    }
}

.dashboard_actions .portal_button {
    white-space: nowrap;
}

.account_dropdown a.account_sign_out {
    display: block;
    text-decoration: none;
    margin-bottom: 8px;
}

.portal_table td.table_center {
    text-align: center;
}

#new_ticket_cancel {
    margin-right: auto;
}

.attachment_list {
    display: grid;
    gap: 10px;
    margin-top: 12px;
}

.attachment_card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px;
    border: 1px solid #547284;
    border-radius: 6px;
    background: #24313a;
}

.attachment_card>div {
    flex: 1;
    min-width: 0;
    overflow-wrap: anywhere;
}

.attachment_card .form_hint {
    margin: 5px 0 0;
}

.attachment_icon {
    font-size: 28px;
    color: #8dd1ff;
}

.tickets_heading_actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.ticket_requests_panel {
    margin-bottom: 24px;
}

.ticket_requests_panel h2 {
    font-size: 18px;
    margin: 0 0 12px;
}

.ticket_request_card {
    padding: 16px;
    margin-bottom: 10px;
    background: #21313c;
    border: 1px solid #4a687c;
    border-radius: 7px;
}

.ticket_request_heading {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    flex-wrap: wrap;
}

.ticket_request_card p {
    margin: 10px 0 0;
    overflow-wrap: anywhere;
}

.portal_toast {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 10000;
    display: flex;
    align-items: center;
    gap: 12px;
    max-width: calc(100vw - 48px);
    padding: 18px;
    color: #ecfff1;
    background: #214d36;
    border: 1px solid #5ca779;
    border-radius: 8px;
    box-shadow: 0 8px 24px #0006;
    animation: portal_toast_dismiss 6s linear forwards;
}

.portal_toast button {
    color: inherit;
    background: none;
    border: 0;
    cursor: pointer;
    font-size: 24px;
}

@keyframes portal_toast_dismiss {
    0%, 90% {
        opacity: 1;
    }

    100% {
        opacity: 0;
    }
}

@media (prefers-reduced-motion:reduce) {
    .portal_toast {
        animation-timing-function: steps(1, end);
    }
}

.ticket_request_card .request_summary {
    font-size: 18px;
    line-height: 1.5;
    white-space: pre-wrap;
}

.request_actions {
    display: flex;
    gap: 12px;
    margin-top: 16px;
}
#ticket_actions .ticket_actions_chevron { margin-left:10px; }
