/* ==========================================================
   Ticket - Form options
========================================================== */

.ticket-option-row {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    width: 100%;
    margin: 12px 0;
    text-align: left;
    cursor: pointer;
}

.ticket-option-row input[type="checkbox"],
.ticket-option-row input[type="radio"] {
    flex: 0 0 18px;
    width: 18px;
    height: 18px;
    margin: 0;
}

.ticket-option-row span {
    flex: 1;
    text-align: left;
    font-weight: 500;
    line-height: 1.4;
}

/* ==========================================================
   Ticket - Gestione stato
========================================================== */

.gh-ticket-mobile-panel,
.gh-ticket-desktop-panel {
    width: 100%;
}

.gh-ticket-mobile-panel .ticket-status-actions,
.gh-ticket-desktop-panel .ticket-status-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
}

.gh-ticket-mobile-panel .ticket-status-actions form,
.gh-ticket-desktop-panel .ticket-status-actions form {
    width: 100%;
    margin: 0;
    padding: 0;
}

.gh-ticket-mobile-panel .ticket-status-action,
.gh-ticket-desktop-panel .ticket-status-action {
    display: block;
    width: 100%;
    min-height: 72px;
    box-sizing: border-box;
    text-align: left;
    border: 0;
    border-radius: 14px;
    padding: 14px 16px;
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.25;
    cursor: pointer;
}

.gh-ticket-mobile-panel .ticket-status-action small,
.gh-ticket-desktop-panel .ticket-status-action small {
    display: block;
    margin-top: 4px;
    font-weight: 400;
    opacity: .9;
}

.ticket-status-current {
    background: #6b7280 !important;
}

.ticket-status-active-progress {
    background: #2563eb;
}

.ticket-status-active-suspended {
    background: #f59e0b;
}

.ticket-status-closed,
.ticket-status-active-closed {
    background: #16a34a;
}

/* ==========================================================
   Ticket - Chiusura
========================================================== */

.ticket-close-panel {
    margin-top: 18px;
    border-top: 1px solid #e5e7eb;
    padding-top: 16px;
}

.ticket-close-panel[hidden],
.is-hidden {
    display: none !important;
}

/* ==========================================================
   Ticket - Sidebar desktop
========================================================== */

@media (min-width: 900px) {
    .ticket-detail-grid > div:last-child {
        position: sticky;
        top: 90px;
        align-self: start;
    }
}

/* ==========================================================
   Ticket - Tempo impiegato
========================================================== */

.ticket-duration-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin: 10px 0 16px;
}

.ticket-duration-choice {
    border: 1px solid #d1d5db;
    background: #fff;
    color: #111827;
    border-radius: 14px;
    padding: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: all .18s ease;
}

.ticket-duration-choice.is-selected {
    border-color: #2563eb;
    background: #eff6ff;
    color: #1d4ed8;
    transform: scale(1.03);
}

.ticket-duration-choice.is-selected::before {
    content: "✓ ";
}
