/**
 * Support Panel Addon Styles
 *
 * @package Polanger_Ticket_System_Pro
 */

/* ==========================================================================
   Variables & Base
   ========================================================================== */

.pgtsp-support-panel {
    --pgtsp-primary: #8b5cf6;
    --pgtsp-primary-dark: #7c3aed;
    --pgtsp-primary-light: #a78bfa;
    --pgtsp-success: #10b981;
    --pgtsp-warning: #f59e0b;
    --pgtsp-danger: #ef4444;
    --pgtsp-info: #3b82f6;
    --pgtsp-gray-50: #f9fafb;
    --pgtsp-gray-100: #f3f4f6;
    --pgtsp-gray-200: #e5e7eb;
    --pgtsp-gray-300: #d1d5db;
    --pgtsp-gray-400: #9ca3af;
    --pgtsp-gray-500: #6b7280;
    --pgtsp-gray-600: #4b5563;
    --pgtsp-gray-700: #374151;
    --pgtsp-gray-800: #1f2937;
    --pgtsp-gray-900: #111827;
    --pgtsp-radius: 12px;
    --pgtsp-radius-sm: 8px;
    --pgtsp-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --pgtsp-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);

    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    font-size: 14px;
    line-height: 1.5;
    color: var(--pgtsp-gray-800);
    background: var(--pgtsp-gray-50);
    min-height: 600px;
}

.pgtsp-support-panel * {
    box-sizing: border-box;
}

.pgtsp-support-panel a {
    text-decoration: none !important;
}

.pgtsp-support-panel a:hover,
.pgtsp-support-panel a:focus,
.pgtsp-support-panel a:visited {
    text-decoration: none !important;
}

/* ==========================================================================
   Login Panel
   ========================================================================== */

.pgtsp-login-panel {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 500px;
    padding: 40px 20px;
}

.pgtsp-login-container {
    width: 100%;
    max-width: 400px;
    background: #fff;
    border-radius: var(--pgtsp-radius);
    box-shadow: var(--pgtsp-shadow-lg);
    padding: 40px;
}

.pgtsp-login-header {
    text-align: center;
    margin-bottom: 32px;
}

.pgtsp-login-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--pgtsp-primary) 0%, var(--pgtsp-primary-dark) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.pgtsp-login-icon .dashicons {
    font-size: 28px;
    width: 28px;
    height: 28px;
    color: #fff;
}

.pgtsp-login-header h2 {
    margin: 0 0 8px;
    font-size: 24px;
    font-weight: 700;
    color: var(--pgtsp-gray-900);
}

.pgtsp-login-header p {
    margin: 0;
    color: var(--pgtsp-gray-500);
}

.pgtsp-login-form .pgtsp-form-group {
    margin-bottom: 20px;
}

.pgtsp-login-form label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: var(--pgtsp-gray-700);
}

.pgtsp-login-form input {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--pgtsp-gray-300);
    border-radius: var(--pgtsp-radius-sm);
    font-size: 14px;
    transition: all 0.2s ease;
}

.pgtsp-login-form input:focus {
    outline: none;
    border-color: var(--pgtsp-primary);
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
}

.pgtsp-form-error {
    background: #fef2f2;
    color: #dc2626;
    padding: 12px 16px;
    border-radius: var(--pgtsp-radius-sm);
    margin-bottom: 16px;
    font-size: 14px;
    font-weight: 500;
    border: 1px solid #fecaca;
}

.pgtsp-login-footer {
    text-align: center;
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid var(--pgtsp-gray-200);
}

.pgtsp-login-footer p {
    margin: 0 0 12px;
    color: var(--pgtsp-gray-500);
    font-size: 13px;
}

.pgtsp-link {
    color: var(--pgtsp-primary);
    text-decoration: none;
    font-weight: 500;
}

.pgtsp-link:hover {
    text-decoration: underline;
}

/* ==========================================================================
   No Access Panel
   ========================================================================== */

.pgtsp-no-access-panel {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 400px;
    padding: 40px 20px;
}

.pgtsp-no-access-container {
    text-align: center;
    max-width: 400px;
}

.pgtsp-no-access-icon {
    width: 80px;
    height: 80px;
    background: var(--pgtsp-gray-100);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
}

.pgtsp-no-access-icon .dashicons {
    font-size: 36px;
    width: 36px;
    height: 36px;
    color: var(--pgtsp-gray-400);
}

.pgtsp-no-access-container h2 {
    margin: 0 0 12px;
    font-size: 24px;
    color: var(--pgtsp-gray-900);
}

.pgtsp-no-access-container p {
    margin: 0 0 24px;
    color: var(--pgtsp-gray-500);
}

.pgtsp-no-access-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.pgtsp-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    border: none;
    border-radius: var(--pgtsp-radius-sm);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none !important;
}

.pgtsp-btn:hover,
.pgtsp-btn:focus,
.pgtsp-btn:visited {
    text-decoration: none !important;
}

.pgtsp-btn-primary {
    background: linear-gradient(135deg, var(--pgtsp-primary) 0%, var(--pgtsp-primary-dark) 100%);
    color: #fff !important;
}

.pgtsp-btn-primary * {
    color: #fff !important;
}

.pgtsp-btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.4);
    color: #fff !important;
}

.pgtsp-btn-primary:hover * {
    color: #fff !important;
}

.pgtsp-btn-secondary {
    background: var(--pgtsp-gray-100);
    color: var(--pgtsp-gray-700) !important;
}

.pgtsp-btn-secondary:hover {
    background: var(--pgtsp-gray-200);
    color: var(--pgtsp-gray-800) !important;
}

.pgtsp-btn-text {
    background: transparent;
    color: var(--pgtsp-gray-600);
    padding: 8px 12px;
}

.pgtsp-btn-text:hover {
    color: var(--pgtsp-gray-900);
    background: var(--pgtsp-gray-100);
}

.pgtsp-btn-block {
    width: 100%;
}

.pgtsp-btn .dashicons {
    font-size: 18px;
    width: 18px;
    height: 18px;
}

/* ==========================================================================
   Spinner
   ========================================================================== */

.pgtsp-spinner {
    display: inline-block;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: pgtsp-spin 0.8s linear infinite;
}

.pgtsp-loading .pgtsp-spinner {
    border-color: rgba(139, 92, 246, 0.2);
    border-top-color: var(--pgtsp-primary);
}

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

.pgtsp-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 40px;
    color: var(--pgtsp-gray-500);
}

/* ==========================================================================
   Main Panel Layout
   ========================================================================== */

.pgtsp-panel-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 24px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #8b5cf6 100%);
    border-bottom: none;
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.3);
}

.pgtsp-panel-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.pgtsp-panel-brand-icon {
    width: 42px;
    height: 42px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(10px);
}

.pgtsp-panel-brand .dashicons {
    font-size: 22px;
    width: 22px;
    height: 22px;
    color: #fff;
}

.pgtsp-brand-text {
    font-size: 20px;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.pgtsp-panel-user {
    display: flex;
    align-items: center;
    gap: 16px;
}

.pgtsp-user-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.pgtsp-user-info img {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.4);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.pgtsp-user-name {
    font-weight: 600;
    color: #fff;
}

.pgtsp-user-badge {
    background: rgba(255, 255, 255, 0.25);
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    backdrop-filter: blur(10px);
}

.pgtsp-logout-btn {
    color: rgba(255, 255, 255, 0.9) !important;
    background: rgba(255, 255, 255, 0.15) !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    border-radius: 8px !important;
    padding: 8px 14px !important;
    transition: all 0.2s ease !important;
}

.pgtsp-logout-btn:hover {
    background: rgba(255, 255, 255, 0.25) !important;
    color: #fff !important;
}

.pgtsp-panel-content {
    display: flex;
    min-height: calc(100vh - 74px);
}

.pgtsp-panel-sidebar {
    width: 260px;
    background: linear-gradient(180deg, #1e1b4b 0%, #312e81 50%, #3730a3 100%);
    border-right: none;
    padding: 24px 0;
    flex-shrink: 0;
    box-shadow: 4px 0 20px rgba(30, 27, 75, 0.15);
    display: flex;
    flex-direction: column;
}

.pgtsp-panel-nav {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 0 16px;
}

.pgtsp-nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    border-radius: 10px;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none !important;
    transition: all 0.2s ease;
    font-weight: 500;
}

.pgtsp-nav-item:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff !important;
    transform: translateX(4px);
    text-decoration: none !important;
}

.pgtsp-nav-item:focus,
.pgtsp-nav-item:visited {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none !important;
}

.pgtsp-nav-item.active {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.4) 0%, rgba(124, 58, 237, 0.4) 100%);
    color: #fff !important;
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.3);
    text-decoration: none !important;
}

.pgtsp-nav-item .dashicons {
    font-size: 20px;
    width: 20px;
    height: 20px;
}

.pgtsp-panel-stats {
    margin-top: 32px;
    padding: 20px 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.pgtsp-stats-title {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 16px;
    padding: 0 4px;
}

.pgtsp-stat-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    margin-bottom: 8px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    transition: all 0.2s ease;
}

.pgtsp-stat-item:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: translateX(4px);
}

.pgtsp-stat-item:last-child {
    margin-bottom: 0;
}

.pgtsp-stat-value {
    font-size: 20px;
    font-weight: 700;
    color: #fff;
}

.pgtsp-stat-label {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
}

.pgtsp-stat-item.stat-open .pgtsp-stat-value {
    color: #4ade80;
}

.pgtsp-stat-item.stat-waiting .pgtsp-stat-value {
    color: #fbbf24;
}

.pgtsp-stat-item.stat-closed .pgtsp-stat-value {
    color: #94a3b8;
}

.pgtsp-sidebar-footer {
    margin-top: auto;
    padding: 20px 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.pgtsp-sidebar-info {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 12px;
}

.pgtsp-sidebar-info .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
    color: rgba(255, 255, 255, 0.4);
}

.pgtsp-panel-main {
    flex: 1;
    padding: 24px;
    overflow-y: auto;
    background: var(--pgtsp-gray-50);
    min-height: 0;
}

/* ==========================================================================
   Views
   ========================================================================== */

.pgtsp-view-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
}

.pgtsp-view-header h2 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: var(--pgtsp-gray-900);
}

.pgtsp-view-filters {
    display: flex;
    gap: 12px;
}

.pgtsp-select {
    padding: 8px 32px 8px 12px;
    border: 1px solid var(--pgtsp-gray-300);
    border-radius: var(--pgtsp-radius-sm);
    background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236b7280' d='M6 8L1 3h10z'/%3E%3C/svg%3E") no-repeat right 12px center;
    appearance: none;
    font-size: 14px;
    cursor: pointer;
}

.pgtsp-select:focus {
    outline: none;
    border-color: var(--pgtsp-primary);
}

/* ==========================================================================
   Tickets List
   ========================================================================== */

.pgtsp-tickets-list {
    background: #fff;
    border-radius: var(--pgtsp-radius);
    box-shadow: var(--pgtsp-shadow);
    overflow: hidden;
}

.pgtsp-ticket-item {
    display: flex;
    align-items: flex-start;
    padding: 20px;
    border-bottom: 1px solid var(--pgtsp-gray-100);
    cursor: pointer;
    transition: all 0.2s ease;
    gap: 16px;
}

.pgtsp-ticket-item:hover {
    background: var(--pgtsp-gray-50);
    transform: translateX(4px);
}

.pgtsp-ticket-item:last-child {
    border-bottom: none;
}

.pgtsp-ticket-status-indicator {
    width: 4px;
    min-height: 60px;
    border-radius: 4px;
    flex-shrink: 0;
}

.pgtsp-ticket-status-indicator.status-open {
    background: linear-gradient(180deg, var(--pgtsp-success) 0%, #059669 100%);
}

.pgtsp-ticket-status-indicator.status-in_progress {
    background: linear-gradient(180deg, var(--pgtsp-info) 0%, #2563eb 100%);
}

.pgtsp-ticket-status-indicator.status-waiting_customer {
    background: linear-gradient(180deg, var(--pgtsp-warning) 0%, #d97706 100%);
}

.pgtsp-ticket-status-indicator.status-waiting_agent {
    background: linear-gradient(180deg, var(--pgtsp-info) 0%, #2563eb 100%);
}

.pgtsp-ticket-status-indicator.status-closed,
.pgtsp-ticket-status-indicator.status-resolved {
    background: linear-gradient(180deg, var(--pgtsp-gray-400) 0%, var(--pgtsp-gray-500) 100%);
}

.pgtsp-ticket-content {
    flex: 1;
    min-width: 0;
}

.pgtsp-ticket-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
}

.pgtsp-ticket-subject {
    font-weight: 600;
    font-size: 15px;
    color: var(--pgtsp-gray-900);
    margin: 0;
    line-height: 1.4;
}

.pgtsp-ticket-badges {
    display: flex;
    gap: 6px;
    flex-shrink: 0;
    flex-wrap: wrap;
}

.pgtsp-badge {
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    white-space: nowrap;
}

.pgtsp-badge-status {
    background: var(--pgtsp-gray-100);
    color: var(--pgtsp-gray-600);
}

.pgtsp-badge-status.status-open {
    background: #dcfce7;
    color: #166534;
}

.pgtsp-badge-status.status-in_progress {
    background: #dbeafe;
    color: #1e40af;
}

.pgtsp-badge-status.status-waiting_customer {
    background: #fef3c7;
    color: #92400e;
}

.pgtsp-badge-status.status-waiting_agent {
    background: #e0e7ff;
    color: #3730a3;
}

.pgtsp-badge-status.status-closed,
.pgtsp-badge-status.status-resolved {
    background: var(--pgtsp-gray-200);
    color: var(--pgtsp-gray-600);
}

.pgtsp-badge-priority {
    background: var(--pgtsp-gray-100);
    color: var(--pgtsp-gray-600);
}

.pgtsp-badge-priority.priority-low {
    background: #ecfdf5;
    color: #059669;
}

.pgtsp-badge-priority.priority-normal,
.pgtsp-badge-priority.priority-medium {
    background: #fef3c7;
    color: #d97706;
}

.pgtsp-badge-priority.priority-high {
    background: #fee2e2;
    color: #dc2626;
}

.pgtsp-badge-priority.priority-urgent {
    background: #dc2626;
    color: #fff;
}

.pgtsp-ticket-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 13px;
    color: var(--pgtsp-gray-500);
    flex-wrap: wrap;
}

.pgtsp-ticket-meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.pgtsp-ticket-meta-item .dashicons {
    font-size: 14px;
    width: 14px;
    height: 14px;
    color: var(--pgtsp-gray-400);
}

.pgtsp-ticket-id {
    color: var(--pgtsp-primary);
    font-weight: 600;
}

.pgtsp-ticket-arrow {
    color: var(--pgtsp-gray-300);
    flex-shrink: 0;
    transition: transform 0.2s ease;
}

.pgtsp-ticket-item:hover .pgtsp-ticket-arrow {
    color: var(--pgtsp-primary);
    transform: translateX(4px);
}

.pgtsp-ticket-arrow .dashicons {
    font-size: 20px;
    width: 20px;
    height: 20px;
}

/* Legacy support */
.pgtsp-ticket-status {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-right: 16px;
    flex-shrink: 0;
}

.pgtsp-ticket-status.status-open {
    background: var(--pgtsp-success);
}

.pgtsp-ticket-status.status-waiting_customer {
    background: var(--pgtsp-warning);
}

.pgtsp-ticket-status.status-waiting_agent {
    background: var(--pgtsp-info);
}

.pgtsp-ticket-status.status-closed {
    background: var(--pgtsp-gray-400);
}

.pgtsp-ticket-info {
    flex: 1;
    min-width: 0;
}

.pgtsp-ticket-priority {
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.pgtsp-ticket-priority.priority-low {
    background: #ecfdf5;
    color: #059669;
}

.pgtsp-ticket-priority.priority-medium {
    background: #fef3c7;
    color: #d97706;
}

.pgtsp-ticket-priority.priority-high {
    background: #fef2f2;
    color: #dc2626;
}

.pgtsp-ticket-priority.priority-urgent {
    background: #dc2626;
    color: #fff;
}

.pgtsp-tickets-empty {
    text-align: center;
    padding: 60px 20px;
    color: var(--pgtsp-gray-500);
}

.pgtsp-tickets-empty .dashicons {
    font-size: 48px;
    width: 48px;
    height: 48px;
    color: var(--pgtsp-gray-300);
    margin-bottom: 16px;
}

/* ==========================================================================
   Forms
   ========================================================================== */

.pgtsp-form {
    background: #fff;
    border-radius: var(--pgtsp-radius);
    box-shadow: var(--pgtsp-shadow);
    padding: 24px;
}

.pgtsp-form-group {
    margin-bottom: 20px;
}

.pgtsp-form-row {
    display: flex;
    gap: 20px;
}

.pgtsp-form-half {
    flex: 1;
}

.pgtsp-form label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: var(--pgtsp-gray-700);
}

.pgtsp-form label .required {
    color: var(--pgtsp-danger);
}

.pgtsp-form input[type="text"],
.pgtsp-form input[type="email"],
.pgtsp-form textarea,
.pgtsp-form select {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid var(--pgtsp-gray-300);
    border-radius: var(--pgtsp-radius-sm);
    font-size: 14px;
    transition: all 0.2s ease;
}

.pgtsp-form input:focus,
.pgtsp-form textarea:focus,
.pgtsp-form select:focus {
    outline: none;
    border-color: var(--pgtsp-primary);
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
}

.pgtsp-form textarea {
    resize: vertical;
    min-height: 120px;
}

.pgtsp-form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid var(--pgtsp-gray-200);
}

/* ==========================================================================
   Ticket Detail
   ========================================================================== */

.pgtsp-back-btn {
    margin-bottom: 16px;
}

.pgtsp-ticket-detail-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: var(--pgtsp-radius);
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.3);
    padding: 16px 24px;
    margin-bottom: 24px;
    color: #fff;
}

.pgtsp-ticket-header-left {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    min-width: 0;
}

.pgtsp-ticket-detail-title {
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    margin: 0;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pgtsp-ticket-header-left .pgtsp-ticket-id {
    background: rgba(255, 255, 255, 0.2);
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    color: #fff;
    white-space: nowrap;
}

.pgtsp-ticket-header-right {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.pgtsp-ticket-header-right .pgtsp-badge {
    padding: 5px 12px;
    font-size: 11px;
}

.pgtsp-header-meta {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.9);
    background: rgba(255, 255, 255, 0.15);
    padding: 5px 12px;
    border-radius: 20px;
}

.pgtsp-header-meta .dashicons {
    font-size: 14px;
    width: 14px;
    height: 14px;
}

.pgtsp-ticket-detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 32px;
}

.pgtsp-detail-item {
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 100px;
}

.pgtsp-detail-label {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.7);
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.pgtsp-detail-value {
    font-weight: 600;
    color: #fff;
    font-size: 14px;
}

.pgtsp-detail-value .pgtsp-badge-status,
.pgtsp-detail-value .pgtsp-badge-priority,
.pgtsp-detail-value .pgtsp-ticket-priority {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
    backdrop-filter: blur(10px);
}

.pgtsp-detail-value .pgtsp-badge-status.status-open {
    background: rgba(74, 222, 128, 0.3);
    color: #bbf7d0;
}

.pgtsp-detail-value .pgtsp-badge-status.status-closed {
    background: rgba(148, 163, 184, 0.3);
    color: #e2e8f0;
}

.pgtsp-detail-value .pgtsp-badge-status.status-waiting_customer,
.pgtsp-detail-value .pgtsp-badge-status.status-waiting_agent,
.pgtsp-detail-value .pgtsp-badge-status.status-in_progress {
    background: rgba(251, 191, 36, 0.3);
    color: #fef3c7;
}

.pgtsp-detail-value .pgtsp-badge-priority.priority-low,
.pgtsp-detail-value .pgtsp-ticket-priority.priority-low {
    background: rgba(74, 222, 128, 0.3);
    color: #bbf7d0;
}

.pgtsp-detail-value .pgtsp-badge-priority.priority-medium,
.pgtsp-detail-value .pgtsp-ticket-priority.priority-medium {
    background: rgba(251, 191, 36, 0.3);
    color: #fef3c7;
}

.pgtsp-detail-value .pgtsp-badge-priority.priority-high,
.pgtsp-detail-value .pgtsp-ticket-priority.priority-high {
    background: rgba(248, 113, 113, 0.3);
    color: #fecaca;
}

.pgtsp-detail-value .pgtsp-badge-priority.priority-urgent,
.pgtsp-detail-value .pgtsp-ticket-priority.priority-urgent {
    background: rgba(220, 38, 38, 0.5);
    color: #fff;
}

.pgtsp-ticket-messages {
    margin-bottom: 24px;
}

.pgtsp-message {
    display: flex;
    gap: 16px;
    margin-bottom: 20px;
}

.pgtsp-message-avatar img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
}

.pgtsp-message-content {
    flex: 1;
    background: #fff;
    border-radius: var(--pgtsp-radius);
    box-shadow: var(--pgtsp-shadow);
    padding: 16px;
}

.pgtsp-message.is-staff .pgtsp-message-content {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.05) 0%, rgba(124, 58, 237, 0.05) 100%);
    border-left: 3px solid var(--pgtsp-primary);
}

.pgtsp-message.is-internal .pgtsp-message-content {
    background: #fffbeb;
    border-left: 3px solid var(--pgtsp-warning);
}

.pgtsp-message-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.pgtsp-message-author {
    font-weight: 600;
    color: var(--pgtsp-gray-900);
}

.pgtsp-message-badge {
    font-size: 10px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 4px;
    text-transform: uppercase;
    margin-left: 8px;
}

.pgtsp-message-badge.badge-staff {
    background: var(--pgtsp-primary);
    color: #fff;
}

.pgtsp-message-badge.badge-internal {
    background: var(--pgtsp-warning);
    color: #fff;
}

.pgtsp-message-time {
    font-size: 12px;
    color: var(--pgtsp-gray-500);
}

.pgtsp-message-body {
    color: var(--pgtsp-gray-700);
    line-height: 1.6;
}

.pgtsp-message-body p {
    margin: 0 0 12px;
}

.pgtsp-message-body p:last-child {
    margin-bottom: 0;
}

/* Reply Form */
.pgtsp-reply-form {
    background: #fff;
    border-radius: var(--pgtsp-radius);
    box-shadow: var(--pgtsp-shadow);
    padding: 20px;
}

.pgtsp-reply-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
}

.pgtsp-reply-tab {
    padding: 8px 16px;
    border: none;
    background: var(--pgtsp-gray-100);
    border-radius: var(--pgtsp-radius-sm);
    font-size: 13px;
    font-weight: 500;
    color: var(--pgtsp-gray-600);
    cursor: pointer;
    transition: all 0.2s ease;
}

.pgtsp-reply-tab:hover {
    background: var(--pgtsp-gray-200);
}

.pgtsp-reply-tab.active {
    background: var(--pgtsp-primary);
    color: #fff;
}

.pgtsp-reply-tab.tab-internal.active {
    background: var(--pgtsp-warning);
}

.pgtsp-reply-textarea {
    width: 100%;
    min-height: 100px;
    padding: 12px;
    border: 1px solid var(--pgtsp-gray-300);
    border-radius: var(--pgtsp-radius-sm);
    resize: vertical;
    font-size: 14px;
    margin-bottom: 16px;
}

.pgtsp-reply-textarea:focus {
    outline: none;
    border-color: var(--pgtsp-primary);
}

.pgtsp-reply-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    padding-top: 16px;
    border-top: 1px solid var(--pgtsp-gray-200);
    margin-top: 16px;
}

.pgtsp-ticket-actions {
    display: flex !important;
    flex-direction: row !important;
    align-items: center;
    gap: 10px;
    flex-wrap: nowrap;
}

.pgtsp-ticket-actions .pgtsp-btn {
    padding: 10px 16px;
    font-size: 13px;
    border-radius: 8px;
}

.pgtsp-ticket-actions .pgtsp-btn-secondary {
    background: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%);
    border: 1px solid var(--pgtsp-gray-300);
    color: var(--pgtsp-gray-700) !important;
}

.pgtsp-ticket-actions .pgtsp-btn-secondary:hover {
    background: linear-gradient(135deg, #e2e8f0 0%, #cbd5e1 100%);
    color: var(--pgtsp-gray-800) !important;
}

.pgtsp-ticket-actions select {
    border: 1px solid var(--pgtsp-gray-300);
    border-radius: 8px;
    font-size: 13px;
    background: #fff;
    color: var(--pgtsp-gray-700);
    cursor: pointer;
    min-width: 140px;
}

.pgtsp-ticket-actions select:focus {
    outline: none;
    border-color: var(--pgtsp-primary);
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
}

.pgtsp-reply-actions .pgtsp-btn-primary {
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
}

/* ==========================================================================
   Modal
   ========================================================================== */

.pgtsp-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.pgtsp-modal.pgtsp-modal-open {
    opacity: 1;
    visibility: visible;
}

.pgtsp-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

/* Define CSS variables for modal since it's outside .pgtsp-support-panel */
.pgtsp-modal {
    --pgtsp-primary: #8b5cf6;
    --pgtsp-primary-dark: #7c3aed;
    --pgtsp-primary-light: #a78bfa;
    --pgtsp-success: #10b981;
    --pgtsp-warning: #f59e0b;
    --pgtsp-danger: #ef4444;
    --pgtsp-info: #3b82f6;
    --pgtsp-gray-50: #f9fafb;
    --pgtsp-gray-100: #f3f4f6;
    --pgtsp-gray-200: #e5e7eb;
    --pgtsp-gray-300: #d1d5db;
    --pgtsp-gray-400: #9ca3af;
    --pgtsp-gray-500: #6b7280;
    --pgtsp-gray-600: #4b5563;
    --pgtsp-gray-700: #374151;
    --pgtsp-gray-800: #1f2937;
    --pgtsp-gray-900: #111827;
    --pgtsp-radius: 12px;
    --pgtsp-radius-sm: 8px;
}

.pgtsp-modal-content {
    position: relative;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    padding: 32px;
    max-width: 400px;
    width: 90%;
    text-align: center;
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.pgtsp-modal.pgtsp-modal-open .pgtsp-modal-content {
    transform: scale(1);
}

.pgtsp-modal-content.pgtsp-modal-large {
    max-width: 500px;
    text-align: left;
}

/* X button in top-right corner - only when it has dashicons inside */
.pgtsp-modal-content > .pgtsp-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--pgtsp-gray-400);
    padding: 4px;
    transition: color 0.2s ease;
    z-index: 10;
}

.pgtsp-modal-content > .pgtsp-modal-close:hover {
    color: var(--pgtsp-gray-600);
}

.pgtsp-modal-content > .pgtsp-modal-close .dashicons {
    font-size: 24px;
    width: 24px;
    height: 24px;
}

/* Cancel button in modal actions - normal button style */
.pgtsp-modal-actions .pgtsp-modal-close {
    position: static;
}

.pgtsp-modal-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}

.pgtsp-modal-icon .dashicons {
    font-size: 32px;
    width: 32px;
    height: 32px;
}

.pgtsp-modal-icon-warning {
    background: #fef3c7;
    color: #d97706;
}

.pgtsp-modal-icon-info {
    background: #e0e7ff;
    color: #6366f1;
}

.pgtsp-modal-icon-danger {
    background: #fee2e2;
    color: #dc2626;
}

.pgtsp-modal-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--pgtsp-gray-900);
    margin: 0 0 12px;
}

.pgtsp-modal-text {
    font-size: 14px;
    color: var(--pgtsp-gray-600);
    margin: 0 0 24px;
    line-height: 1.6;
}

.pgtsp-modal-text strong {
    color: var(--pgtsp-gray-900);
}

.pgtsp-modal-textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--pgtsp-gray-300);
    border-radius: 8px;
    font-size: 14px;
    resize: vertical;
    min-height: 100px;
}

.pgtsp-modal-textarea:focus {
    outline: none;
    border-color: var(--pgtsp-primary);
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
}

.pgtsp-form-hint {
    font-size: 12px;
    color: var(--pgtsp-gray-500);
    margin-top: 8px;
}

.pgtsp-modal-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.pgtsp-modal-content.pgtsp-modal-large .pgtsp-modal-actions {
    justify-content: flex-end;
}

/* Modal buttons - use fixed colors since modal is outside .pgtsp-support-panel */
.pgtsp-modal-actions .pgtsp-btn-primary {
    background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%) !important;
    color: #fff !important;
    border: none;
}

.pgtsp-modal-actions .pgtsp-btn-primary:hover {
    background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 100%) !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.4);
}

.pgtsp-modal-actions .pgtsp-btn-secondary {
    background: #f3f4f6 !important;
    color: #374151 !important;
    border: 1px solid #e5e7eb;
}

.pgtsp-modal-actions .pgtsp-btn-secondary:hover {
    background: #e5e7eb !important;
    color: #1f2937 !important;
}

.pgtsp-btn-danger {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: #fff !important;
}

.pgtsp-btn-danger:hover {
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.4);
    color: #fff !important;
}

/* ==========================================================================
   Claim System Styles
   ========================================================================== */

/* Claim badges in ticket list */
.pgtsp-badge-claim {
    font-size: 10px;
    padding: 3px 8px;
    border-radius: 12px;
    font-weight: 600;
}

.pgtsp-badge-claim.claim-available {
    background: #dcfce7;
    color: #166534;
}

.pgtsp-badge-claim.claim-mine {
    background: #dbeafe;
    color: #1e40af;
}

.pgtsp-badge-claim.claim-locked {
    background: #fee2e2;
    color: #991b1b;
}

.pgtsp-badge-claim.claim-admin-view {
    background: #f3e8ff;
    color: #7c3aed;
}

/* Ticket item claim states */
.pgtsp-ticket-item.claim-locked {
    opacity: 0.7;
    background: #fef2f2;
}

.pgtsp-ticket-item.claim-locked:hover {
    background: #fee2e2;
}

.pgtsp-ticket-item.claim-mine {
    background: #eff6ff;
    border-left: 3px solid #3b82f6;
}

.pgtsp-ticket-item.claim-mine:hover {
    background: #dbeafe;
}

/* Claim badge in ticket detail header */
.pgtsp-claim-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    margin-left: 8px;
}

.pgtsp-claim-badge .dashicons {
    font-size: 14px;
    width: 14px;
    height: 14px;
}

.pgtsp-claim-badge.claim-mine {
    background: rgba(74, 222, 128, 0.3);
    color: #bbf7d0;
}

.pgtsp-claim-badge.claim-locked {
    background: rgba(248, 113, 113, 0.3);
    color: #fecaca;
}

.pgtsp-claim-badge.claim-admin-view {
    background: rgba(139, 92, 246, 0.3);
    color: #e9d5ff;
}

/* Release button */
.pgtsp-btn-release {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: #fff;
    padding: 6px 10px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.pgtsp-btn-release:hover {
    background: rgba(255, 255, 255, 0.3);
}

.pgtsp-btn-release .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
}

/* ==========================================================================
   Agents List
   ========================================================================== */

.pgtsp-agents-list {
    background: #fff;
    border-radius: var(--pgtsp-radius);
    box-shadow: var(--pgtsp-shadow);
    overflow: hidden;
}

.pgtsp-agent-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    border-bottom: 1px solid var(--pgtsp-gray-100);
}

.pgtsp-agent-item:last-child {
    border-bottom: none;
}

.pgtsp-agent-avatar img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
}

.pgtsp-agent-info {
    flex: 1;
}

.pgtsp-agent-name {
    font-weight: 600;
    color: var(--pgtsp-gray-900);
}

.pgtsp-agent-email {
    font-size: 13px;
    color: var(--pgtsp-gray-500);
}

.pgtsp-agents-info {
    margin-top: 16px;
    padding: 16px;
    background: var(--pgtsp-gray-100);
    border-radius: var(--pgtsp-radius-sm);
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.pgtsp-agents-info .dashicons {
    color: var(--pgtsp-info);
    flex-shrink: 0;
}

.pgtsp-agents-info p {
    margin: 0;
    font-size: 13px;
    color: var(--pgtsp-gray-600);
}

/* ==========================================================================
   Pagination
   ========================================================================== */

.pgtsp-pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 24px;
}

.pgtsp-pagination button {
    padding: 8px 14px;
    border: 1px solid var(--pgtsp-gray-300);
    background: #fff;
    border-radius: var(--pgtsp-radius-sm);
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.pgtsp-pagination button:hover {
    border-color: var(--pgtsp-primary);
    color: var(--pgtsp-primary);
}

.pgtsp-pagination button.active {
    background: var(--pgtsp-primary);
    border-color: var(--pgtsp-primary);
    color: #fff;
}

.pgtsp-pagination button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

/* Tablet */
@media (max-width: 1024px) {
    .pgtsp-panel-sidebar {
        width: 200px;
    }

    .pgtsp-ticket-header {
        flex-direction: column;
        gap: 8px;
    }

    .pgtsp-ticket-badges {
        justify-content: flex-start;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .pgtsp-support-panel {
        min-height: auto;
    }

    .pgtsp-panel-topbar {
        padding: 12px 16px;
        flex-direction: row;
        justify-content: space-between;
    }

    .pgtsp-panel-brand-icon {
        width: 36px;
        height: 36px;
        border-radius: 10px;
    }

    .pgtsp-panel-brand .dashicons {
        font-size: 18px;
        width: 18px;
        height: 18px;
    }

    .pgtsp-brand-text {
        font-size: 16px;
    }

    .pgtsp-panel-user {
        flex-direction: row;
        gap: 8px;
    }

    .pgtsp-user-info {
        display: none;
    }

    .pgtsp-logout-btn {
        padding: 6px 12px !important;
        font-size: 13px !important;
    }

    .pgtsp-panel-content {
        flex-direction: column;
    }

    .pgtsp-panel-sidebar {
        width: 100%;
        border-right: none;
        padding: 0;
        position: sticky;
        top: 0;
        z-index: 10;
        background: linear-gradient(135deg, #1e1b4b 0%, #312e81 100%);
        box-shadow: 0 4px 15px rgba(30, 27, 75, 0.2);
    }

    .pgtsp-panel-nav {
        flex-direction: row;
        overflow-x: auto;
        padding: 12px;
        gap: 8px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .pgtsp-panel-nav::-webkit-scrollbar {
        display: none;
    }

    .pgtsp-nav-item {
        white-space: nowrap;
        padding: 10px 16px;
        font-size: 13px;
        border-radius: 8px;
    }

    .pgtsp-panel-stats {
        display: flex;
        flex-direction: row;
        margin-top: 0;
        padding: 12px;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
        gap: 8px;
        justify-content: center;
        background: rgba(0, 0, 0, 0.1);
    }

    .pgtsp-stats-title {
        display: none;
    }

    .pgtsp-stat-item {
        flex-direction: column;
        align-items: center;
        padding: 8px 16px;
        margin-bottom: 0;
        flex: 1;
    }

    .pgtsp-stat-value {
        font-size: 18px;
    }

    .pgtsp-stat-label {
        font-size: 10px;
        color: rgba(255, 255, 255, 0.6);
    }

    .pgtsp-sidebar-footer {
        display: none;
    }

    .pgtsp-panel-main {
        padding: 12px;
    }

    .pgtsp-view-header {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
        margin-bottom: 16px;
    }

    .pgtsp-view-header h2 {
        font-size: 18px;
    }

    .pgtsp-view-filters {
        width: 100%;
    }

    .pgtsp-view-filters .pgtsp-select {
        flex: 1;
    }

    /* Ticket List Mobile */
    .pgtsp-tickets-list {
        border-radius: var(--pgtsp-radius-sm);
    }

    .pgtsp-ticket-item {
        padding: 16px;
        gap: 12px;
    }

    .pgtsp-ticket-status-indicator {
        min-height: 50px;
    }

    .pgtsp-ticket-header {
        flex-direction: column;
        gap: 8px;
    }

    .pgtsp-ticket-subject {
        font-size: 14px;
    }

    .pgtsp-ticket-badges {
        justify-content: flex-start;
    }

    .pgtsp-badge {
        padding: 3px 8px;
        font-size: 10px;
    }

    .pgtsp-ticket-meta {
        gap: 8px;
        font-size: 12px;
    }

    .pgtsp-ticket-arrow {
        display: none;
    }

    /* Forms Mobile */
    .pgtsp-form {
        padding: 16px;
        border-radius: var(--pgtsp-radius-sm);
    }

    .pgtsp-form-row {
        flex-direction: column;
        gap: 0;
    }

    .pgtsp-form-actions {
        flex-direction: column-reverse;
        gap: 8px;
    }

    .pgtsp-form-actions .pgtsp-btn {
        width: 100%;
    }

    /* Ticket Detail Mobile */
    .pgtsp-ticket-detail-header {
        padding: 16px;
        margin-bottom: 16px;
        border-radius: 12px;
    }

    .pgtsp-ticket-detail-title {
        font-size: 16px;
        margin-bottom: 16px;
    }

    .pgtsp-ticket-detail-meta {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .pgtsp-detail-item {
        min-width: auto;
    }

    .pgtsp-detail-label {
        font-size: 10px;
    }

    .pgtsp-detail-value {
        font-size: 13px;
    }

    .pgtsp-message {
        gap: 12px;
    }

    .pgtsp-message-avatar img {
        width: 32px;
        height: 32px;
    }

    .pgtsp-message-content {
        padding: 12px;
    }

    .pgtsp-reply-form {
        padding: 16px;
    }

    .pgtsp-reply-tabs {
        flex-wrap: wrap;
    }

    .pgtsp-reply-actions {
        flex-direction: column;
        gap: 12px;
    }

    .pgtsp-ticket-actions {
        width: auto;
        justify-content: flex-start;
        flex-direction: row !important;
        flex-wrap: nowrap !important;
    }

    .pgtsp-ticket-actions .pgtsp-btn,
    .pgtsp-ticket-actions select {
        flex: 0 0 auto;
        min-width: auto;
    }

    .pgtsp-reply-actions .pgtsp-btn-primary {
        width: 100%;
    }

    /* Pagination Mobile */
    .pgtsp-pagination {
        flex-wrap: wrap;
    }

    .pgtsp-pagination button {
        padding: 8px 12px;
        font-size: 13px;
    }

    /* Login Mobile */
    .pgtsp-login-container {
        padding: 24px;
        margin: 16px;
    }

    .pgtsp-login-header h2 {
        font-size: 20px;
    }
}

/* Small Mobile */
@media (max-width: 480px) {
    .pgtsp-panel-topbar {
        padding: 10px 12px;
    }

    .pgtsp-brand-text {
        font-size: 14px;
    }

    .pgtsp-panel-brand .dashicons {
        font-size: 20px;
        width: 20px;
        height: 20px;
    }

    .pgtsp-nav-item {
        padding: 8px 12px;
        font-size: 12px;
    }

    .pgtsp-panel-main {
        padding: 8px;
    }

    .pgtsp-ticket-item {
        padding: 12px;
    }

    .pgtsp-ticket-subject {
        font-size: 13px;
    }

    .pgtsp-ticket-meta {
        font-size: 11px;
    }

    .pgtsp-stat-item {
        padding: 4px 8px;
    }

    .pgtsp-stat-value {
        font-size: 14px;
    }

    .pgtsp-stat-label {
        font-size: 10px;
    }
}

/* ==========================================================================
   Customer Search (for Agents/Admins)
   ========================================================================== */

.pgtsp-customer-search-wrapper {
    position: relative;
}

.pgtsp-customer-search-wrapper input[type="text"] {
    width: 100%;
}

.pgtsp-customer-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid var(--pgtsp-gray-300);
    border-top: none;
    border-radius: 0 0 var(--pgtsp-radius-sm) var(--pgtsp-radius-sm);
    max-height: 200px;
    overflow-y: auto;
    z-index: 100;
    box-shadow: var(--pgtsp-shadow);
    display: none;
}

.pgtsp-customer-result {
    padding: 10px 14px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    gap: 2px;
    border-bottom: 1px solid var(--pgtsp-gray-200);
}

.pgtsp-customer-result:last-child {
    border-bottom: none;
}

.pgtsp-customer-result:hover {
    background: var(--pgtsp-gray-100);
}

.pgtsp-customer-name {
    font-weight: 500;
    color: var(--pgtsp-gray-800);
}

.pgtsp-customer-email {
    font-size: 12px;
    color: var(--pgtsp-gray-500);
}

.pgtsp-customer-selected {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    background: var(--pgtsp-gray-100);
    border: 1px solid var(--pgtsp-gray-300);
    border-radius: var(--pgtsp-radius-sm);
}

.pgtsp-customer-selected .pgtsp-selected-name {
    flex: 1;
    font-weight: 500;
}

.pgtsp-remove-customer {
    background: none;
    border: none;
    font-size: 18px;
    color: var(--pgtsp-gray-500);
    cursor: pointer;
    padding: 0;
    line-height: 1;
}

.pgtsp-remove-customer:hover {
    color: var(--pgtsp-danger);
}

.pgtsp-no-results {
    padding: 12px 14px;
    color: var(--pgtsp-gray-500);
    text-align: center;
    font-size: 13px;
}

/* ==========================================================================
   Real-time Notifications
   ========================================================================== */

.pgtsp-notification {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    border-radius: var(--pgtsp-radius);
    margin-bottom: 16px;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    pointer-events: none;
}

.pgtsp-notification-show {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.pgtsp-notification-info {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: #fff;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.pgtsp-notification .dashicons {
    font-size: 20px;
    width: 20px;
    height: 20px;
}

.pgtsp-notification-text {
    flex: 1;
    font-weight: 500;
}

.pgtsp-notification-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s;
}

.pgtsp-notification-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

.pgtsp-notification-close .dashicons {
    font-size: 14px;
    width: 14px;
    height: 14px;
}


/* ==========================================================================
   Pagination Fix - Button colors
   ========================================================================== */

.pgtsp-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
}

.pgtsp-pagination button,
.pgtsp-pagination .pgtsp-page-btn {
    min-width: 36px;
    height: 36px;
    padding: 0 12px;
    border: 1px solid var(--pgtsp-gray-300);
    border-radius: var(--pgtsp-radius-sm);
    background: #fff;
    color: var(--pgtsp-gray-700);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.pgtsp-pagination button:hover,
.pgtsp-pagination .pgtsp-page-btn:hover {
    background: var(--pgtsp-gray-100);
    border-color: var(--pgtsp-gray-400);
}

.pgtsp-pagination button.active,
.pgtsp-pagination .pgtsp-page-btn.active {
    background: var(--pgtsp-primary);
    border-color: var(--pgtsp-primary);
    color: #fff;
}

.pgtsp-pagination button:disabled,
.pgtsp-pagination .pgtsp-page-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ==========================================================================
   Claim Badge Styling
   ========================================================================== */

.pgtsp-claim-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    background: var(--pgtsp-warning);
    color: #fff;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 500;
}

.pgtsp-claim-badge .dashicons {
    font-size: 12px;
    width: 12px;
    height: 12px;
}

/* ==========================================================================
   Release Button & Icon Fixes
   ========================================================================== */

.pgtsp-btn-release {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 10px;
    background: var(--pgtsp-warning);
    color: #fff;
    border: none;
    border-radius: var(--pgtsp-radius-sm);
    cursor: pointer;
    transition: all 0.2s ease;
}

.pgtsp-btn-release:hover {
    background: #d97706;
}

.pgtsp-btn-release .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
    line-height: 1;
}

/* Ensure dashicons display correctly */
.pgtsp-support-panel .dashicons {
    font-family: dashicons;
    display: inline-block;
    line-height: 1;
    font-weight: 400;
    font-style: normal;
    speak: never;
    text-decoration: inherit;
    text-transform: none;
    text-rendering: auto;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Header icons */
.pgtsp-panel-brand-icon .dashicons {
    font-size: 24px;
    width: 24px;
    height: 24px;
    color: #fff;
}

.pgtsp-header-meta .dashicons {
    font-size: 14px;
    width: 14px;
    height: 14px;
    margin-right: 4px;
    vertical-align: middle;
}

/* ==========================================================================
   Reply Attachments
   ========================================================================== */

.pgtsp-reply-attachments-wrapper {
    margin: 12px 0;
}

.pgtsp-reply-dropzone {
    border: 2px dashed var(--pgtsp-gray-300);
    border-radius: var(--pgtsp-radius-sm);
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    background: var(--pgtsp-gray-50);
}

.pgtsp-reply-dropzone:hover,
.pgtsp-reply-dropzone.dragover {
    border-color: var(--pgtsp-primary);
    background: rgba(139, 92, 246, 0.05);
}

.pgtsp-dropzone-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: var(--pgtsp-gray-500);
}

.pgtsp-dropzone-content .dashicons {
    font-size: 20px;
    width: 20px;
    height: 20px;
}

.pgtsp-dropzone-text {
    font-size: 13px;
}

#pgtsp-reply-attachment-preview {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

#pgtsp-reply-attachment-preview .pgtsp-attachment-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: var(--pgtsp-gray-100);
    border-radius: var(--pgtsp-radius-sm);
    font-size: 13px;
}

#pgtsp-reply-attachment-preview .pgtsp-attachment-item.uploading {
    opacity: 0.7;
}

#pgtsp-reply-attachment-preview .pgtsp-file-icon .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
    color: var(--pgtsp-gray-500);
}

#pgtsp-reply-attachment-preview .pgtsp-file-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

#pgtsp-reply-attachment-preview .pgtsp-file-name {
    font-weight: 500;
    color: var(--pgtsp-gray-700);
    max-width: 150px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

#pgtsp-reply-attachment-preview .pgtsp-file-status {
    font-size: 11px;
    color: var(--pgtsp-gray-400);
}

#pgtsp-reply-attachment-preview .pgtsp-remove-attachment {
    background: none;
    border: none;
    padding: 2px;
    cursor: pointer;
    color: var(--pgtsp-gray-400);
    transition: color 0.2s;
}

#pgtsp-reply-attachment-preview .pgtsp-remove-attachment:hover {
    color: var(--pgtsp-danger);
}

#pgtsp-reply-attachment-preview .pgtsp-remove-attachment .dashicons {
    font-size: 14px;
    width: 14px;
    height: 14px;
}

/* ==========================================================================
   Message Attachments Display
   ========================================================================== */

.pgtsp-message-attachments {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--pgtsp-gray-200);
}

.pgtsp-attachments-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 600;
    color: var(--pgtsp-gray-500);
    margin-bottom: 8px;
}

.pgtsp-attachments-label .dashicons {
    font-size: 14px;
    width: 14px;
    height: 14px;
}

.pgtsp-attachments-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.pgtsp-attachment-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    background: var(--pgtsp-gray-100);
    border-radius: var(--pgtsp-radius-sm);
    font-size: 12px;
    color: var(--pgtsp-gray-700) !important;
    transition: all 0.2s ease;
    text-decoration: none !important;
}

.pgtsp-attachment-link:hover {
    background: var(--pgtsp-primary-light);
    color: #fff !important;
}

.pgtsp-attachment-link .dashicons {
    font-size: 14px;
    width: 14px;
    height: 14px;
    color: var(--pgtsp-primary);
}

.pgtsp-attachment-link:hover .dashicons {
    color: #fff;
}

.pgtsp-attachment-name {
    max-width: 150px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pgtsp-attachment-size {
    color: var(--pgtsp-gray-400);
    font-size: 11px;
}

.pgtsp-attachment-link:hover .pgtsp-attachment-size {
    color: rgba(255, 255, 255, 0.8);
}

/* ==========================================================================
   Image Gallery
   ========================================================================== */

.pgtsp-image-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 8px;
    margin-bottom: 10px;
}

@media (min-width: 768px) {
    .pgtsp-image-gallery {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    }
}

.pgtsp-gallery-item {
    position: relative;
    aspect-ratio: 1;
    border-radius: var(--pgtsp-radius-sm);
    overflow: hidden;
    cursor: pointer;
    background: var(--pgtsp-gray-100);
}

.pgtsp-gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.pgtsp-gallery-item:hover img {
    transform: scale(1.05);
}

.pgtsp-gallery-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.pgtsp-gallery-item:hover .pgtsp-gallery-overlay {
    opacity: 1;
}

.pgtsp-gallery-overlay .dashicons {
    color: #fff;
    font-size: 24px;
    width: 24px;
    height: 24px;
}

/* Files List */
.pgtsp-files-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.pgtsp-file-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: var(--pgtsp-gray-100);
    border-radius: var(--pgtsp-radius-sm);
    font-size: 13px;
    color: var(--pgtsp-gray-700) !important;
    text-decoration: none !important;
    transition: all 0.2s ease;
}

.pgtsp-file-link:hover {
    background: var(--pgtsp-primary);
    color: #fff !important;
}

.pgtsp-file-link .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
    color: var(--pgtsp-primary);
}

.pgtsp-file-link:hover .dashicons {
    color: #fff;
}

.pgtsp-file-name {
    max-width: 150px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pgtsp-file-size {
    color: var(--pgtsp-gray-400);
    font-size: 11px;
}

.pgtsp-file-link:hover .pgtsp-file-size {
    color: rgba(255, 255, 255, 0.8);
}

/* ==========================================================================
   Image Lightbox
   ========================================================================== */

.pgtsp-lightbox {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.pgtsp-lightbox.pgtsp-lightbox-open {
    opacity: 1;
    visibility: visible;
}

.pgtsp-lightbox-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    cursor: pointer;
}

.pgtsp-lightbox-content {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    z-index: 1;
}

.pgtsp-lightbox-content img {
    max-width: 100%;
    max-height: calc(90vh - 60px);
    object-fit: contain;
    border-radius: var(--pgtsp-radius);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.pgtsp-lightbox-close {
    position: absolute;
    top: -40px;
    right: 0;
    background: none;
    border: none;
    color: #fff;
    cursor: pointer;
    padding: 8px;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.pgtsp-lightbox-close:hover {
    opacity: 1;
}

.pgtsp-lightbox-close .dashicons {
    font-size: 24px;
    width: 24px;
    height: 24px;
}

.pgtsp-lightbox-caption {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 16px;
    color: #fff;
}

.pgtsp-lightbox-name {
    font-size: 14px;
    opacity: 0.9;
}

.pgtsp-lightbox-download {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: var(--pgtsp-primary);
    border-radius: 50%;
    color: #fff !important;
    transition: background 0.2s;
}

.pgtsp-lightbox-download:hover {
    background: var(--pgtsp-primary-dark);
}

.pgtsp-lightbox-download .dashicons {
    font-size: 18px;
    width: 18px;
    height: 18px;
}

/* Mobile adjustments */
@media (max-width: 767px) {
    .pgtsp-lightbox-content {
        max-width: 95vw;
    }
    
    .pgtsp-lightbox-close {
        top: -35px;
        right: -5px;
    }
}

/* ==========================================================================
   Ticket Closed Banner (Support Panel)
   ========================================================================== */
.pgtsp-ticket-closed-banner {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 20px 24px;
    background: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%);
    border: 1px solid #cbd5e1;
    border-radius: var(--pgtsp-radius);
    margin-top: 20px;
}

.pgtsp-ticket-closed-banner .pgtsp-closed-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, #94a3b8 0%, #64748b 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.pgtsp-ticket-closed-banner .pgtsp-closed-icon .dashicons {
    font-size: 24px;
    width: 24px;
    height: 24px;
    color: #fff;
}

.pgtsp-ticket-closed-banner .pgtsp-closed-content {
    flex: 1;
    min-width: 0;
}

.pgtsp-ticket-closed-banner .pgtsp-closed-content strong {
    display: block;
    font-size: 16px;
    color: #1e293b;
    margin-bottom: 4px;
}

.pgtsp-ticket-closed-banner .pgtsp-closed-desc {
    font-size: 13px;
    color: #64748b;
}

.pgtsp-ticket-closed-banner .pgtsp-close-info {
    margin-top: 8px;
}

.pgtsp-ticket-closed-banner .pgtsp-close-meta {
    display: block;
    font-size: 12px;
    color: #64748b;
    margin-bottom: 8px;
}

.pgtsp-ticket-closed-banner .pgtsp-close-meta strong {
    color: #475569;
    font-size: 12px;
    display: inline;
}

.pgtsp-ticket-closed-banner .pgtsp-close-reason-box {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 10px 12px;
}

.pgtsp-ticket-closed-banner .pgtsp-close-reason-label {
    display: block;
    font-size: 11px;
    font-weight: 600;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.pgtsp-ticket-closed-banner .pgtsp-close-reason-text {
    display: block;
    font-size: 13px;
    color: #334155;
    line-height: 1.5;
    white-space: pre-wrap;
}

.pgtsp-ticket-closed-banner .pgtsp-btn {
    flex-shrink: 0;
    align-self: center;
}

.pgtsp-ticket-closed-banner .pgtsp-btn .dashicons {
    margin-right: 4px;
    font-size: 16px;
    width: 16px;
    height: 16px;
    vertical-align: middle;
}

@media (max-width: 767px) {
    .pgtsp-ticket-closed-banner {
        flex-direction: column;
        text-align: center;
        align-items: center;
    }
    
    .pgtsp-ticket-closed-banner .pgtsp-close-info {
        text-align: left;
    }
    
    .pgtsp-ticket-closed-banner .pgtsp-btn {
        width: 100%;
        justify-content: center;
    }
}

/* ==========================================================================
   NEW Ticket Badge - Animated Pulse Effect
   ========================================================================== */

/* Priority Customer badge (VIP) */
.pgtsp-badge-priority-customer {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #fff;
    font-weight: 700;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 4px 10px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
}

/* NEW badge with pulse animation */
.pgtsp-badge-new {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #fff;
    font-weight: 700;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 4px 10px;
    border-radius: 12px;
    animation: pgtsp-new-pulse 2s ease-in-out infinite;
    position: relative;
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
}

/* Pulse animation - glow effect */
@keyframes pgtsp-new-pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
        transform: scale(1);
    }
    50% {
        box-shadow: 0 0 0 8px rgba(16, 185, 129, 0);
        transform: scale(1.05);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
        transform: scale(1);
    }
}

/* New ticket item - subtle highlight border */
.pgtsp-ticket-item.is-new-ticket {
    position: relative;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.05) 0%, rgba(255, 255, 255, 1) 100%);
    border-left: 4px solid #10b981;
}

.pgtsp-ticket-item.is-new-ticket::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: inherit;
    padding: 2px;
    background: linear-gradient(90deg, #10b981, #34d399, #10b981);
    background-size: 200% 100%;
    animation: pgtsp-border-wave 3s linear infinite;
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
    opacity: 0.6;
}

/* Wave animation for border */
@keyframes pgtsp-border-wave {
    0% {
        background-position: 0% 50%;
    }
    100% {
        background-position: 200% 50%;
    }
}

/* Hover state for new tickets */
.pgtsp-ticket-item.is-new-ticket:hover {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.1) 0%, rgba(255, 255, 255, 1) 100%);
}

.pgtsp-ticket-item.is-new-ticket:hover::before {
    opacity: 1;
}

/* ==========================================================================
   Assignment Status Badges
   ========================================================================== */

/* Assigned to you badge - prominent green */
.pgtsp-badge-claim.claim-assigned-mine {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #fff;
    font-weight: 600;
    animation: pgtsp-assigned-pulse 2s ease-in-out infinite;
}

@keyframes pgtsp-assigned-pulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.4);
    }
    50% {
        box-shadow: 0 0 0 6px rgba(16, 185, 129, 0);
    }
}

/* Assigned to another agent badge - orange/warning */
.pgtsp-badge-claim.claim-assigned {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #fff;
    font-weight: 500;
}

/* Claim badge in header for assigned tickets */
.pgtsp-claim-badge.claim-assigned-mine {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #fff;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.pgtsp-claim-badge.claim-assigned {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #fff;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

/* Ticket item styling for assigned tickets */
.pgtsp-ticket-item.claim-assigned-mine {
    border-left: 4px solid #10b981;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.05) 0%, #fff 100%);
}

.pgtsp-ticket-item.claim-assigned {
    border-left: 4px solid #f59e0b;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.05) 0%, #fff 100%);
    opacity: 0.85;
}

/* ==========================================================================
   No Products Notice
   ========================================================================== */

.pgtsp-no-products-notice {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 16px;
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border: 1px solid #f59e0b;
    border-radius: 8px;
    color: #92400e;
    font-size: 14px;
}

.pgtsp-no-products-notice .dashicons {
    color: #d97706;
    font-size: 20px;
    width: 20px;
    height: 20px;
}

/* ==========================================================================
   SLA Indicators
   ========================================================================== */

.pgtsp-sla-indicators {
    display: flex;
    gap: 8px;
    margin-right: 12px;
}

.pgtsp-sla-badge {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 16px;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
}

.pgtsp-sla-icon {
    font-size: 12px;
}

.pgtsp-sla-label {
    opacity: 0.9;
}

.pgtsp-sla-time {
    font-weight: 700;
}

/* SLA Status Colors */
.pgtsp-sla-badge.sla-ok {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #fff;
}

.pgtsp-sla-badge.sla-warning {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #fff;
    animation: pgtsp-sla-pulse 2s ease-in-out infinite;
}

.pgtsp-sla-badge.sla-breached {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: #fff;
    animation: pgtsp-sla-pulse 1s ease-in-out infinite;
}

.pgtsp-sla-badge.sla-met {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
    color: #fff;
}

.pgtsp-sla-badge.sla-paused {
    background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
    color: #fff;
}

.pgtsp-sla-badge.sla-frozen {
    opacity: 0.6;
    animation: none !important;
}

@keyframes pgtsp-sla-pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

/* SLA in ticket list */
.pgtsp-ticket-item .pgtsp-sla-mini {
    display: flex;
    gap: 6px;
    margin-top: 6px;
}

.pgtsp-sla-mini-badge {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 2px 6px;
    border-radius: 10px;
    font-size: 10px;
    font-weight: 600;
}

.pgtsp-sla-mini-badge.sla-ok {
    background: rgba(16, 185, 129, 0.15);
    color: #059669;
}

.pgtsp-sla-mini-badge.sla-warning {
    background: rgba(245, 158, 11, 0.15);
    color: #d97706;
}

.pgtsp-sla-mini-badge.sla-breached {
    background: rgba(239, 68, 68, 0.15);
    color: #dc2626;
}

/* ==========================================================================
   Real-time Message Animation
   ========================================================================== */

@keyframes pgtsp-message-slide-in {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.pgtsp-message-new {
    animation: pgtsp-message-slide-in 0.4s ease-out;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.08), rgba(59, 130, 246, 0.02));
    border-left: 3px solid var(--pgtsp-primary);
}

/* ==========================================================================
   Related Order Modal & Button
   ========================================================================== */

.pgtsp-view-header-flex {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.pgtsp-view-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.pgtsp-related-order-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, #c6c8ff 0%, #cfcdee 100%);
    color: #fff;
    border: none;
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.pgtsp-related-order-btn:hover {
    background: linear-gradient(135deg, #4f46e5 0%, #4338ca 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.pgtsp-related-order-btn .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
}

/* Related Order Modal */
.pgtsp-related-order-modal {
    opacity: 1;
    visibility: visible;
}

.pgtsp-related-order-modal .pgtsp-modal-container {
    max-width: 500px;
    width: 90%;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    transform: scale(1);
    position: relative;
    z-index: 10001;
}

.pgtsp-related-order-modal .pgtsp-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid #e5e7eb;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
}

.pgtsp-related-order-modal .pgtsp-modal-header h3 {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
}

.pgtsp-related-order-modal .pgtsp-modal-header .dashicons {
    color: #6366f1;
}

.pgtsp-related-order-modal .pgtsp-modal-close {
    background: none;
    border: none;
    cursor: pointer;
    color: #6b7280;
    padding: 4px;
    border-radius: 4px;
    transition: all 0.2s;
}

.pgtsp-related-order-modal .pgtsp-modal-close:hover {
    background: #f3f4f6;
    color: #1f2937;
}

.pgtsp-related-order-modal .pgtsp-modal-body {
    padding: 20px;
}

/* Order Modal Content */
.pgtsp-order-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e5e7eb;
}

.pgtsp-order-number-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 22px;
    font-weight: 700;
    color: #6366f1;
    text-decoration: none;
}

.pgtsp-order-number-link:hover {
    color: #4f46e5;
}

.pgtsp-order-number-link .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
}

.pgtsp-order-status-badge {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.pgtsp-order-modal-details {
    margin-bottom: 20px;
}

.pgtsp-order-modal-details .pgtsp-order-detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px dashed #e5e7eb;
}

.pgtsp-order-modal-details .pgtsp-order-detail-row:last-child {
    border-bottom: none;
}

.pgtsp-order-modal-details .pgtsp-detail-label {
    color: #6b7280;
    font-size: 13px;
}

.pgtsp-order-modal-details .pgtsp-detail-value {
    font-weight: 500;
    color: #1f2937;
}

.pgtsp-order-modal-details .pgtsp-order-total {
    color: #10b981;
    font-weight: 600;
    font-size: 15px;
}

.pgtsp-order-modal-products,
.pgtsp-order-modal-address {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #e5e7eb;
}

.pgtsp-order-modal-products h4,
.pgtsp-order-modal-address h4 {
    font-size: 11px;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 0 0 12px 0;
}

.pgtsp-order-product-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.pgtsp-order-product-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #f3f4f6;
}

.pgtsp-order-product-list li:last-child {
    border-bottom: none;
}

.pgtsp-order-product-list .pgtsp-product-name {
    flex: 1;
    font-size: 13px;
    color: #374151;
}

.pgtsp-order-product-list .pgtsp-product-meta {
    font-size: 12px;
    color: #9ca3af;
    margin-left: 12px;
}

.pgtsp-order-modal-address address {
    font-style: normal;
    font-size: 13px;
    color: #4b5563;
    line-height: 1.6;
}
