/* * 05_card_actions.css 
 * Contains: Remove button, batch delete bar, countdowns
 */

/* ---------------------------------- */
/* 11. Show Card - State & Actions  */
/* ---------------------------------- */

/* 11a. Card Top Bar */
.card-top-bar {
    display: flex;
    justify-content: center; /* Pushes logo to the right */
	padding: 8px 10px 20px 10px; /* Adds 8px padding to the bottom */
    height: 80px; /* Gives the bar a consistent height */
    box-sizing: border-box;
	border-bottom: 1px solid #468915;
	background-color: #2b2e2b;
}

.card-platform-logo {
    height: 100%; /* Fills the height of the bar */
    max-height: 80px; /* Control the actual logo size */
    width: auto;
    max-width: 250px; /* Don't let it get too wide */
    object-fit: contain;
    opacity: 0.7; /* Make it subtle */
	object-fit:contain;
}

#showsContainer.list-view .card-top-bar {
    display: none;
}

.card-top-bar .status-badge.ended {
    position: static;
    margin: 0;
}

/* 11b. Batch Delete Mode Styles */
#batchDeleteBar {
    background-color: var(--danger-color);
    color: white;
    padding: 10px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 100;
    margin-bottom: 20px;
    border-radius: 8px;
    animation: fadeIn 0.3s;
}

#batchDeleteCount {
    font-weight: bold;
}

.batch-delete-btn {
    background-color: transparent;
    border: 1px solid rgba(255, 255, 255, 0.5);
    color: white;
    padding: 8px 12px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s ease;
}

.batch-delete-btn.delete {
    background-color: rgba(0, 0, 0, 0.2);
}

.batch-delete-btn.delete:not(:disabled):hover {
    background-color: white;
    color: var(--danger-color);
}

.batch-delete-btn.cancel:hover {
    background-color: rgba(0, 0, 0, 0.3);
}

.batch-delete-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* --- Styles when batch delete mode is active --- */
#showsContainer.batch-delete-active .show-card {
    opacity: 0.6;
    transition: opacity 0.2s ease, transform 0.2s ease;
    cursor: pointer;
}

#showsContainer.batch-delete-active .show-card:hover {
    opacity: 0.8;
}

/* --- ADD THIS NEW BLOCK --- */

/* Hide the indicator by default */
.batch-delete-indicator {
    display: none;
}

/* Show and style the indicator (empty circle) in batch delete mode */
#showsContainer.batch-delete-active .batch-delete-indicator {
    display: block;
    position: absolute;
    top: 10px;
    left: 10px;
    width: 28px;
    height: 28px;
    background-color: var(--surface-color);
    border: 2px solid white;
    border-radius: 50%;
    z-index: 7; /* On top of card content (z-index 1) */
    transition: all 0.2s ease;
}

/* Style the checkmark (hidden by default) inside the indicator */
#showsContainer.batch-delete-active .batch-delete-indicator::after {
    content: '\f00c'; /* Font Awesome check icon */
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    position: absolute;
    top: 5px;  /* Centered */
    left: 6px; /* Centered */
    font-size: 16px;
    color: white;
    z-index: 8;
    opacity: 0;
    transform: scale(0.5);
    transition: all 0.2s ease;
}

/* Style the selected state (filled circle) */
#showsContainer.batch-delete-active .card-selected .batch-delete-indicator {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

/* Style the selected state (visible checkmark) */
#showsContainer.batch-delete-active .card-selected .batch-delete-indicator::after {
    opacity: 1;
    transform: scale(1);
}

/* Hide the single 'Remove X' button during batch mode */
#showsContainer.batch-delete-active .show-card .remove-btn {
    display: none;
}

/* Disable clicks on card content during batch mode */
#showsContainer.batch-delete-active .show-card * {
    pointer-events: none;
}

/* 11c. Other States */
.show-card.airing-soon {
    animation: glowing-border 2s ease-in-out infinite;
}

/* --- NEW DAISYUI-STYLE COUNTDOWN --- */

.countdown-timer .tba-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 90px; /* This ensures it matches the skeleton height */
}

/* This styles the "Next Episode: TBA" text */
.countdown-tba-text {
    font-size: 1.1em;
    color: var(--text-color-secondary);
    font-weight: 400;
    display: block;
    text-align: center;
}


/* This styles the outer .countdown-timer div */
.countdown-timer {
    font-size: 0.8rem;
    color: var(--primary-color);
    font-weight: bold;
    height: auto;
    width: 100%; 
    box-sizing: border-box;
    padding: 15px 10px; 
    margin-top: 0; 
    border-top: 1px solid var(--border-color); 
    min-height: 90px; /* This ensures all cards have this section */
    display: flex;        /* This will center fallback text */
	flex-direction: column;
    align-items: center;    /* This will center fallback text */
    justify-content: center; /* This will center fallback text */
}

/* This is your new HTML structure */
.countdown-timer .grid-flow-col {
    display: flex;
    flex-direction: row;
    justify-content: center;
}

.countdown-timer .gap-5 {
    gap: 0px; 
}

.countdown-timer .flex-col {
    display: flex;
    flex-direction: column;
    padding: 0.5rem 0.25rem; /* 8px vertical, 4px horizontal */
    font-size: 0.7rem;
    color: var(--text-color-secondary);
    text-transform: uppercase;
    text-align: center;
    /* This centers the label under the number */
    align-items: center; 
    /* This gives each item a min-width to prevent squishing */
    min-width: 20px; 
}

.countdown-timer .font-mono {
    font-family: monospace;
}

.countdown-timer .text-5xl {
    font-size: 1.8em; /* Adjusted for card */
    font-weight: 700;
    color: #197530;
    line-height: 1.2; /* Give it a bit of space */
}

/* Aired/Long Date styles */
.countdown-aired, .countdown-longdate {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--danger-color);
    margin-top: 8px;
    display: block;
    text-align: center;
    padding: 0.5rem;
}
.countdown-longdate {
    color: var(--text-color-secondary);
    font-weight: 400;
}

/* This centers the "Ended" badge when it's in the timer div */
.countdown-timer.ended-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 90px; /* This ensures it matches the skeleton */
}

/* This makes the badge visible and styled in its new home */
.countdown-timer.ended-container .status-badge.ended {
    display: inline-block;
    font-size: 0.9rem;
    padding: 6px 12px;
}
/* --- ADD THIS NEW BLOCK --- */

/* This ensures the timer grid itself is centered */
.countdown-timer .grid-flow-col {
    width: 100%;
}

/* Style for "Aired!" (in red) */
.countdown-aired {
    font-size: 1.2em;
    font-weight: 700;
    color: var(--danger-color);
    display: block;
    text-align: center;
}

/* Style for "Aired: Today" (in green) */
.countdown-aired-today {
    font-size: 1.2em;
    font-weight: 700;
    color: var(--success-color);
    display: block;
    text-align: center;
}

/* Style for "Airs on: [Date]" (in grey) */
.countdown-longdate {
    font-size: 1.1em;
    color: var(--text-color-secondary);
    font-weight: 400;
    display: block;
    text-align: center;
}