
/* In static/css/base.css */

/* ===================================== */
/*  GLOBAL LOADING OVERLAY STYLES        */
/* ===================================== */

/* In static/css/base.css */

/* --- CORRECTED LOADING OVERLAY STYLES --- */

.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8); /* Slightly darker for more focus */
    display: none; /* Hidden by default */
    z-index: 9999;
    
    /* THE FIX: The outer overlay only needs to center its single child, the content box. */
    display: none;
    justify-content: center;
    align-items: center;
}

.loading-overlay.visible {
    display: flex; /* Show the overlay */
}

/* This is the new container for the actual content */
.loading-overlay .overlay-content {
    /* THE FIX: This is where the column layout and alignment should be. */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    
    color: #ffffff;
    font-size: 1.2em;
    font-weight: 500;
    text-align: center; /* Ensure text is centered */
}

.loading-overlay .spinner {
    width: 60px;
    height: 60px;
    border: 5px solid rgba(255, 255, 255, 0.3);
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
}

.loading-overlay p#overlay-text { /* Be more specific for the text */
    margin: 0;
    letter-spacing: 0.5px;
    min-height: 50px; /* Give it some space so the layout doesn't jump */
}

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

/* in static/css/base.css */

/* --- ADD THESE NEW STYLES FOR OVERLAY ACTION BUTTONS --- */

/* This is the container for the buttons inside the overlay */
#overlay-actions {
    display: flex;
    justify-content: center;
    gap: 15px; /* Space between the buttons */
    margin-top: 25px; /* Space between the text and the buttons */
    width: 100%;
}

/* Base style for any button or link inside the actions container */
#overlay-actions .btn {
    padding: 12px 30px;
    border-radius: 25px; /* Pill shape */
    border: none;
    font-size: 1em;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none; /* For <a> tags */
    display: inline-block;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

#overlay-actions .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
}

/* Primary button style (for "Download") */
/* Reuses the gradient from your other primary buttons */
#overlay-actions .btn-overlay-primary {
    background: linear-gradient(135deg, #6a82fb, #fc5c7d);
    color: white;
}

/* Secondary button style (for "Close") */
#overlay-actions .btn-overlay-secondary {
    background-color: #4a4a4a; /* A dark grey */
    color: #cccccc; /* A light grey text */
}

#overlay-actions .btn-overlay-secondary:hover {
    background-color: #5a5a5a;
}

/* In static/css/base.css or your main stylesheet */

/* --- ADD THESE NEW STYLES FOR CONSISTENT BUTTONS --- */

/* This is a base class for all buttons to share styles */
/* You can apply this to your .btn-gradient as well */
.btn {
    padding: 12px 30px;
    border-radius: 25px;
    border: none;
    font-size: 1.1em;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    text-align: center;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
}

/* Your existing gradient style for primary actions */
.btn-gradient {
    background: linear-gradient(135deg, #6a82fb, #fc5c7d);
    color: white;
}

.btn-secondary {
    background: transparent;
    color: #ffffff;
    border: 2px solid #7b2d2d; /* Soft deep red border */
    padding: 8px 18px;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.25s ease;
}

.btn-secondary:hover {
    background: linear-gradient(90deg, #ff6a6a, #d64545);
    color: white;
    border-color: transparent;
}

