﻿
.ai-queue-overlay-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.45);
    z-index: 9998;
}

.ai-queue-overlay-box {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #fff;
    padding: 20px 28px;
    border-radius: 6px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.25);
    z-index: 9999;
    font-size: 16px;
    min-width: 320px;
    text-align: center;
}

.js-ai-queue-btn[disabled] {
    opacity: 0.65;
    cursor: not-allowed;
}

.tooltip .tooltip-inner {
    max-width: 400px;
    text-align: left;
    font-size: 0.8em;
    padding: 9px 14px;
}

.ai-rec-panel {
    margin-bottom: 10px;
}

.ai-rec-value,
.ai-rec-reason {
    margin-top: 6px;
}

.ai-rec-toggle-wrap {
    margin-top: 8px;
}

.ai-rec-reason-block {
    margin-top: 8px;
}

.ai-rec-reason-lines {
    margin-top: 4px;
}

.ai-rec-reason-line {
    margin-bottom: 4px;
    white-space: normal;
}

.ai-rec-reason-lang {
    font-weight: bold;
}

.ai-rec-action-item {
    position: relative;
    padding-left: 16px;
    margin-bottom: 6px;
}

    .ai-rec-action-item:before {
        content: '-';
        position: absolute;
        left: 0;
        top: 0;
    }

#aiRecommendationLanguageSwitcher .btn {
    margin-right: 0px;
    font-size: 0.8em;
}

.ai-rec-date-box {
    margin-bottom: 10px;
}

    .ai-rec-date-box .form-control {
        margin-top: 6px;
    }
.modal-title {
    display: inline-block;
}

.ai-rec-lang-switcher-wrap {
    display: inline;
    padding-left: 40px;
}

.action-buttons button {
    padding: 2px 5px;
    background: linear-gradient(0deg,rgba(179, 179, 179, 1) 0%, rgba(247, 247, 247, 1) 100%);
    font-size: 12px;
    color: black;
    white-space: nowrap;
    font-weight: bold;
    border-radius: 3px;
}
    .action-buttons button:hover {
        color: black;
        opacity: 0.8;
    }

    .ai-sim-table {
        margin-bottom: 0;
        font-size: 12px;
    }

    .ai-sim-table th,
    .ai-sim-table td {
        vertical-align: top !important;
    }

        .ai-sim-table th:nth-child(1),
        .ai-sim-table td:nth-child(1) {
            width: 110px;
            white-space: nowrap;
        }

        .ai-sim-table th:nth-child(3),
        .ai-sim-table td:nth-child(3) {
            width: 70px;
            white-space: nowrap;
            text-align: right;
        }

        .ai-sim-table th:nth-child(4),
        .ai-sim-table td:nth-child(4) {
            width: 160px;
        }

.ai-btn {
    opacity: 1;
    transition: 500ms;
}
    .ai-btn:hover, .ai-btn:focus {
        opacity: 0.5;
        transition: 500ms;
    }

/* Base Helpix button */
.action-buttons button.helpix-btn {
    text-align: center;
}

    .action-buttons button.helpix-btn .glyphicon {
        margin-left: 4px;
    }

.action-buttons button.btn-success {
    color: white;
    background: #dce35b; /* fallback for old browsers */
    background: -webkit-linear-gradient(to bottom, #5CB85C, #359135); /* Chrome 10-25, Safari 5.1-6 */
    background: linear-gradient(to bottom, #5CB85C, #359135); /* W3C, IE 10+/ Edge, Firefox 16+, Chrome 26+, Opera 12+, Safari 7+ */
}

/* 1) Request recommendation - neutral */
.action-buttons button.helpix-state-request {
    color: #333;
}

/* 2) Request pending - blue/info */
.action-buttons button.helpix-state-pending {
    color: #fff;
    background-image: linear-gradient(to bottom, #5bc0de 0, #2aabd2 100%);
    border-color: #28a4c9;
}

/* Optional spinner for pending */
    .action-buttons button.helpix-state-pending .helpix-spin {
        display: inline-block;
        animation: helpix-spin 1s linear infinite;
        transform-origin: 50% 50%;
    }

@keyframes helpix-spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* 3) Recommendation available - color is provided by inline gradient helper */
.action-buttons button.helpix-state-available {
    color: #fff;
}

/* 4) No recommendation - neutral gray */
.action-buttons button.helpix-state-none {
    color: #777;
    border-color: #ccc;
    background-image: linear-gradient(to bottom, #f5f5f5 0, #d9d9d9 100%);
}

/* 5) Outdated - warning/orange */
.action-buttons button.helpix-state-outdated {
    color: #fff;
    background-image: linear-gradient(to bottom, #f0ad4e 0, #eb9316 100%);
    border-color: #e38d13;
}

    /* Keep readable hover/focus states */
    .action-buttons button.helpix-state-pending:hover,
    .action-buttons button.helpix-state-pending:focus,
    .action-buttons button.helpix-state-available:hover,
    .action-buttons button.helpix-state-available:focus,
    .action-buttons button.helpix-state-outdated:hover,
    .action-buttons button.helpix-state-outdated:focus {
        color: #fff;
    }

.action-buttons button.helpix-state-none:hover,
.action-buttons button.helpix-state-none:focus {
    color: #555;
}


/* Help modal */
.helpix-help-open {
    padding-left: 0;
    padding-right: 0;
}

.helpix-help-dialog {
    width: auto;
    max-width: 900px;
}

.helpix-help-body {
    max-height: calc(100vh - 180px);
    overflow-y: auto;
}

.helpix-help-intro {
    margin-bottom: 15px;
}

.helpix-help-table {
    margin-bottom: 15px;
}

    .helpix-help-table th,
    .helpix-help-table td {
        vertical-align: middle !important;
    }

.helpix-help-preview-col {
    width: 130px;
    white-space: nowrap;
    text-align: center;
}

.helpix-help-note {
    margin-bottom: 0;
}

/* Better behavior on small screens */
@media (max-width: 767px) {
    .helpix-help-dialog {
        margin: 10px;
    }

    .helpix-help-body {
        max-height: calc(100vh - 140px);
        overflow-y: auto;
    }

    .helpix-help-preview-col {
        width: auto;
        white-space: normal;
    }

    .helpix-btn {
        min-width: 82px;
    }
}

.top-help {
    float: right; 
    text-align: right;
}
    .top-help button.btn-link, .top-help .btn-link, .top-help label {
        font-size: 12px;
        line-height: 12px;
    }

/****** duty notes panel ******/

.duty-notes-panel {
    position: fixed;
    top: 70px;
    right: 0;
    width: 380px;
    max-width: calc(100vw - 20px);
    max-height: calc(100vh - 100px);
    overflow-y: auto;
    z-index: 1049;
    transform: translateX(105%);
    transition: transform 0.25s ease-in-out;
}

    .duty-notes-panel.duty-notes-panel-open {
        transform: translateX(0);
    }

.duty-note {
    cursor: pointer;
}

.duty-note-unread {
    background-color: #fff8e1;
    border-left: 4px solid #ffc107;
}

.duty-note:hover {
    background-color: #f8f9fa;
}

@media (max-width: 576px) {
    .duty-notes-panel {
        top: 60px;
        right: 10px;
        width: calc(100vw - 20px);
        border-radius: 0.375rem !important;
    }
}

td.ai-rec-col-value.ai-rec-new-val {
    background: lightgreen;
    font-weight: bold;
}

#dutyNotesList a {
    cursor: pointer;
}
    #dutyNotesList a:hover {
        opacity: 0.8;
    }

.ai-article-preview-wrap {
    position: relative;
}

.ai-article-preview {
    margin-bottom: 0;
}

.ai-article-preview-collapsed {
    max-height: 100px;
    overflow: hidden;
    position: relative;
}

    /* Small fade at bottom when collapsed */
    .ai-article-preview-collapsed:after {
        content: "";
        position: absolute;
        left: 0;
        right: 0;
        bottom: 0;
        height: 18px;
        background: linear-gradient(to bottom, rgba(255,255,255,0), #fff);
        pointer-events: none;
    }

.ai-article-preview-expanded {
    max-height: none;
    overflow: visible;
}

.ai-article-preview-toggle {
    padding-left: 0;
    margin-top: 4px;
}