/*
Plugin: EventON Pre-Registration
Description: Styles for pre-registration forms, buttons, bubbles, tooltips and progress bar
Version: 1.3.1
Updated: 2025-12-23

*/

/* Pre-registration Form */
.prereg-form input, .prereg-form textarea, .prereg-form button {
    width: 100%;
    margin: 10px 0;
    padding: 10px;
    font-size: 16px;
}

.prereg-form button {
    background-color: #0073aa;
    color: white;
    border: none;
    cursor: pointer;
}

.prereg-form button:hover {
    background-color: #005b8c;
}

/* Popup Styling */
#evpr-popup {
    display: none;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 20px;
    position: fixed;
    top: 20%;
    left: 20%;
    right: 20%;
    bottom: 20%;
    z-index: 9999;
    text-align: center;
}

#evpr-popup img {
    max-width: 100%;
    max-height: 300px;
    margin-top: 10px;
}

/* Pre-Register Button */
.evpr-open-modal {
    color: #08244c;
    border: 1px solid #08244c;
    border-radius: 4px;
    background: #ffffff;
    font-family: Raleway, sans-serif;
    font-size: 16px;
    font-weight: 700;
    padding: 0 20px;
    line-height: 34px;
    height: 34px;
    box-sizing: border-box;
    text-transform: uppercase;
    display: inline-block;
    cursor: pointer;
    transition: color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.evpr-open-modal:hover {
    color: #d68e00;
    border: 1px solid #d68e00;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    opacity: 1;
}

/* Progress Bar */
.evpr-progress-container {
    margin: 15px 0 !important;
}

.evpr-progress-bar {
    position: relative;
    width: 100%;
    height: 20px;
    background: #e9ecef;
    border-radius: 10px;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

.evpr-progress-fill {
    height: 100%;
    background: #08244c;
    border-radius: 10px;
    transition: width 0.6s ease, background-color 0.3s ease;
    position: relative;
    overflow: hidden;
}

.evpr-progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.2) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    animation: evpr-shimmer 2s infinite;
}

@keyframes evpr-shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* Marker at 50% (minimum target) */
.evpr-progress-marker {
    position: absolute;
    top: -4px;
    width: 3px;
    height: 28px;
    background: #333;
    transform: translateX(-50%);
    border-radius: 2px;
    z-index: 10;
}

.evpr-progress-marker::after {
    content: 'min';
    position: absolute;
    top: -18px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 10px;
    font-weight: 600;
    color: #555;
    text-transform: uppercase;
}

.evpr-progress-text {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: #555;
}

.evpr-progress-count {
    font-weight: 700;
    color: #08244c;
}

.evpr-progress-label {
    font-style: italic;
    color: #777;
}

/* Minimum reached state */
.evpr-progress-fill.min-reached {
    background: #d68e00;
}

/* Bubbles List */
.evpr-bubbles-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding-top: 10px;
    padding-bottom: 10px;
    border-top: 1px solid #eee;
}

/* Individual Bubble */
.evpr-bubble {
    position: relative;
    display: inline-block;
}

.evpr-bubble-initials {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #08244c;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.evpr-bubble:hover .evpr-bubble-initials {
    transform: scale(1.1);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* Tooltip */
.evpr-bubble-tooltip {
    position: fixed;
    background: #333;
    color: #fff;
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 13px;
    line-height: 2;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
    z-index: 9999;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    pointer-events: none;
}

/* Tooltip arrow */
.evpr-bubble-tooltip::after {
    display: none;
}

.evpr-bubble:hover .evpr-bubble-tooltip {
    opacity: 1;
    visibility: visible;
}

/* Tooltip icons styling */
.evpr-bubble-tooltip i {
    display: inline !important;
    margin-right: 5px;
    width: auto !important;
    vertical-align: baseline;
    color: #8cc;
    float: none !important;
}

/* Countdown Timer */
.evpr-countdown {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin: 15px 0;
    padding-bottom: 10px;
}

.evpr-countdown-label {
    margin: 0;
    font-size: 14px;
    color: #555;
    font-weight: 600;
}

.evpr-countdown-timer {
    display: flex;
    gap: 10px;
}

.evpr-countdown-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 50px;
    padding: 8px;
    background: #08244c;
    border-radius: 6px;
}

.evpr-countdown-value {
    font-size: 24px;
    font-weight: 700;
    color: #fff;
    line-height: 1.2;
}

.evpr-countdown-unit {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.8);
    text-transform: uppercase;
    margin-top: 2px;
}

/* Expired state */
.evpr-countdown-expired {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
}

.evpr-countdown-expired p {
    margin: 0;
    color: #721c24;
    font-weight: 600;
}
