/* ========================================
   TRASH
   Extracted from style.css in Session 168-C
   Source lines: 1709-2262
======================================== */
/* ===== ALERT UNDO BUTTON STYLING ===== */
.alert form button.btn-link {
    text-decoration: none;
    padding: 0;
    margin: 0;
    vertical-align: baseline;
    background: none;
    border: none;
    color: inherit;
    cursor: pointer;
    font-size: inherit;
    font-weight: inherit;
}

.alert form button.btn-link:hover {
    text-decoration: underline;
}

.alert form button.btn-link:focus {
    outline: 2px solid currentColor;
    outline-offset: 2px;
}

/* Undo button loading state */
.alert form button[disabled] {
    opacity: 0.6;
    cursor: not-allowed;
}

.alert form button[disabled]::after {
    content: '...';
    animation: dots 1s steps(4, end) infinite;
}

@keyframes dots {
    0%, 20% { content: ''; }
    40% { content: '.'; }
    60% { content: '..'; }
    80%, 100% { content: '...'; }
}

/* ============================================
   MODERN TOGGLE SWITCH COMPONENT
   ============================================ */

/* Custom toggle switch - larger and more modern than Bootstrap default */
.form-switch.form-switch-lg {
    padding-left: 3.5rem;
    min-height: 2rem;
}

.form-switch.form-switch-lg .form-check-input {
    width: 52px;
    height: 28px;
    margin-left: -3.5rem;
    margin-top: 0;
    cursor: pointer;
    background-color: #e5e7eb;
    border: none;
    border-radius: 14px;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%23fff'/%3e%3c/svg%3e");
    background-position: left center;
    background-size: 22px;
    transition: background-color 0.2s ease-in-out, background-position 0.2s ease-in-out;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

.form-switch.form-switch-lg .form-check-input:checked {
    background-color: #16ba31;  /* Brand green */
    background-position: right center;
}

.form-switch.form-switch-lg .form-check-input:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(22, 186, 49, 0.25);
}

.form-switch.form-switch-lg .form-check-input:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.form-switch.form-switch-lg .form-check-label {
    font-size: 1rem;
    font-weight: 500;
    color: var(--gray-700, #404040);
    padding-top: 0.25rem;
    cursor: pointer;
}

.form-switch.form-switch-lg .form-check-input:disabled + .form-check-label {
    cursor: not-allowed;
    color: var(--gray-500, #737373);
}

/* Toggle helper text */
.toggle-helper-text {
    font-size: 0.875rem;
    color: var(--gray-500, #737373);
    margin-top: 0.25rem;
    margin-left: 3.5rem;
}

/* Status indicator for toggle */
.toggle-status {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    margin-left: 0.5rem;
}

.toggle-status.draft {
    color: #856404;
}

.toggle-status.published {
    color: #0f5132;
}

.toggle-status.pending {
    color: #6c757d;
}

/* ========================================
   TRASH BIN BUTTON & CARD STYLING
   Modern, consistent button hierarchy
   ======================================== */

/* === TRASH CARD STRUCTURE === */
.trash-card-meta {
    padding: 16px;
    padding-bottom: 8px;
}

.trash-card-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--gray-800);
    margin-bottom: 8px;
    line-height: 1.4;
}

.trash-card-info {
    font-size: var(--font-size-xs);
    color: var(--gray-500);
    margin-bottom: 4px;
}

.trash-card-info i {
    width: 16px;
    margin-right: 6px;
    color: var(--gray-400);
}

.trash-card-actions {
    padding: 16px;
    background-color: var(--white);
    border-top: 1px solid var(--gray-200);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* === UNIFIED ACTION BUTTON (Dark Gray - matches .pexels-upload-btn) === */
.trash-btn-action {
    background-color: var(--black, #000);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    padding: var(--btn-padding-sm);
    font-size: var(--btn-text-sm);
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-base);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    min-height: 44px; /* Touch target WCAG AAA */
    text-decoration: none;
    font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
}

.trash-btn-action:hover {
    background-color: var(--gray-900, #171717);
    color: white;
    transform: translateY(-1px);
    /* Future token candidate: --btn-shadow-dark-hover (deliberate literal, not --card-shadow — semantic mismatch; see DEF-195-CARD-SWEEP spec). */
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    text-decoration: none;
}

.trash-btn-action:active {
    transform: translateY(0);
}

.trash-btn-action:focus-visible {
    outline: 2px solid var(--gray-600);
    outline-offset: 2px;
}

/* === DESTRUCTIVE: Delete Forever (Red - 14px) === */
.trash-btn-delete {
    background-color: var(--error);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    padding: var(--btn-padding-sm);
    font-size: var(--btn-text-sm);
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-base);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    min-height: 44px;
    text-decoration: none;
    font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
}

.trash-btn-delete:hover {
    background-color: var(--error-hover);
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.3);
    text-decoration: none;
}

.trash-btn-delete:active {
    transform: translateY(0);
}

.trash-btn-delete:focus-visible {
    outline: 2px solid var(--error);
    outline-offset: 2px;
}

/* === PAGE-LEVEL: Empty Trash (Red, Larger) === */
.trash-btn-empty {
    background-color: var(--error);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    padding: 14px 28px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-base);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    text-decoration: none;
    font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
}

.trash-btn-empty:hover {
    background-color: var(--error-hover);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.3);
    text-decoration: none;
}

.trash-btn-empty:active {
    transform: translateY(0);
}

.trash-btn-empty:focus-visible {
    outline: 2px solid var(--error);
    outline-offset: 2px;
}

/* === MODAL BUTTONS === */
.trash-modal-btn-cancel {
    background-color: var(--gray-100);
    color: var(--gray-700);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-md);
    padding: 10px 20px;
    font-size: var(--font-size-base);
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-base);
    text-decoration: none;
}

.trash-modal-btn-cancel:hover {
    background-color: var(--gray-200);
    color: var(--gray-800);
}

.trash-modal-btn-confirm {
    background-color: var(--error);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    padding: 10px 20px;
    font-size: var(--font-size-base);
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-base);
    text-decoration: none;
}

.trash-modal-btn-confirm:hover {
    background-color: var(--error-hover);
    color: white;
}

/* === EMPTY TRASH MODAL === */
.trash-modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1050;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

.trash-modal-backdrop.show {
    opacity: 1;
    visibility: visible;
}

.trash-modal {
    background-color: var(--white, #FFFFFF);
    border-radius: var(--radius-lg);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
    padding: 32px;
    max-width: 480px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    transform: translateY(-20px);
    transition: transform 0.2s ease;
}

.trash-modal-backdrop.show .trash-modal {
    transform: translateY(0);
}

.trash-modal-title {
    color: var(--error);
    font-size: var(--font-size-lg);
    font-weight: 600;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.trash-modal-body {
    color: var(--gray-700);
    font-size: 16px;
    line-height: 1.5;
    margin-bottom: 20px;
}

.trash-modal-warning {
    background-color: var(--error-light);
    border: 1px solid var(--error);
    color: var(--error-hover);
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 24px;
    font-size: var(--font-size-small);
    line-height: 1.5;
}

.trash-modal-warning strong {
    font-weight: 600;
}

.trash-modal-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-start;
}

/* Enhanced modal button styles for Empty Trash modal */
.trash-modal-actions .trash-modal-btn-confirm {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
}

.trash-modal-actions .trash-modal-btn-confirm:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.3);
}

.trash-modal-actions .trash-modal-btn-cancel {
    padding: 12px 24px;
}

.trash-modal-actions .trash-modal-btn-cancel:hover {
    transform: translateY(-2px);
}

/* === TRASH SUB-TABS (Phase K - Collections Integration) === */
.trash-sub-tabs {
    display: flex;
    gap: 8px;
    border-bottom: 1px solid var(--gray-200);
    padding-bottom: 0;
}

.trash-sub-tab {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    font-size: 15px;
    font-weight: 500;
    color: var(--gray-600);
    text-decoration: none;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
    transition: all 0.15s ease;
}

.trash-sub-tab:hover {
    color: var(--gray-900);
    text-decoration: none;
}

.trash-sub-tab.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
    font-weight: 600;
}

.trash-sub-tab-count {
    background-color: var(--gray-100);
    color: var(--gray-600);
    padding: 2px 8px;
    border-radius: var(--radius-lg);
    font-size: 13px;
    font-weight: 500;
}

.trash-sub-tab.active .trash-sub-tab-count {
    background-color: var(--primary-light);
    color: var(--primary);
}

/* === DELETED COLLECTIONS GRID === */
.deleted-collections-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

.deleted-collection-card {
    background-color: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.deleted-collection-card:hover {
    box-shadow: var(--shadow-md);
}

.deleted-collection-card.removing {
    opacity: 0;
    transform: scale(0.95);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

/* Collection Preview - 2x2 grid of thumbnails */
.deleted-collection-preview {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2px;
    aspect-ratio: 16/9;
    background-color: var(--gray-100);
}

.deleted-collection-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.deleted-collection-placeholder {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-400);
}

/* Collection Info */
.deleted-collection-info {
    padding: 16px;
}

.deleted-collection-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--gray-900);
    margin: 0 0 8px 0;
    line-height: 1.3;
}

.deleted-collection-meta {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: var(--gray-500);
    margin: 0 0 4px 0;
}

.deleted-collection-warning {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: var(--error);
    margin: 0 0 4px 0;
    font-weight: 500;
}

/* Collection Action Buttons */
.deleted-collection-actions {
    display: flex;
    gap: 8px;
    padding: 12px 16px 16px;
    border-top: 1px solid var(--gray-100);
}

.deleted-collection-actions .trash-btn-action,
.deleted-collection-actions .trash-btn-delete {
    flex: 1;
    justify-content: center;
    font-size: 13px;
    padding: 8px 12px;
}
