/**
 * Apply Button Handler - Styles
 * Optimized for JobConer website design
 */

/* Apply Button Styles */
.apply-button-container {
    margin: 30px 0;
    padding: 0;
    clear: both;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

.apply-button-box {
    background: linear-gradient(135deg, #7a9d8f 0%, #6b8e7f 100%);
    border-radius: 12px;
    padding: 25px 20px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(122, 157, 143, 0.25);
    position: relative;
    overflow: hidden;
    max-width: 100%;
}

.apply-button-box h3 {
    color: #ffffff;
    font-size: 20px;
    font-weight: 600;
    margin: 0 0 10px 0;
    text-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.apply-button-box p {
    color: rgba(255, 255, 255, 0.95);
    font-size: 14px;
    line-height: 1.5;
    margin: 0 0 20px 0;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.apply-now-button {
    display: inline-block;
    background: #2d3436;
    color: #ffffff !important;
    padding: 12px 35px;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none !important;
    box-shadow: 0 3px 12px rgba(45, 52, 54, 0.3);
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    letter-spacing: 0.5px;
}

.apply-now-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 18px rgba(45, 52, 54, 0.4);
    background: #1e2426;
    color: #ffffff !important;
}

.apply-button-note {
    color: rgba(255, 255, 255, 0.85);
    font-size: 12px;
    margin: 15px 0 0 0;
    font-style: italic;
}

/* Benefits Grid */
.apply-benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 15px;
    margin-top: 20px;
    text-align: center;
}

.apply-benefit-card {
    padding: 15px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 8px;
    border: 1px solid rgba(122, 157, 143, 0.2);
}

.apply-benefit-card .icon {
    font-size: 28px;
    margin-bottom: 8px;
}

.apply-benefit-card .title {
    font-weight: 600;
    color: #2d3436;
    font-size: 13px;
}

.apply-benefit-card .desc {
    color: #636e72;
    font-size: 11px;
    margin-top: 4px;
}

/* Popup Overlay */
.apply-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(45, 52, 54, 0.95);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 999999;
    overflow-y: auto;
    padding: 15px;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Popup Content */
.apply-popup-content {
    background: linear-gradient(135deg, #7a9d8f 0%, #6b8e7f 100%);
    padding: 30px 25px;
    border-radius: 12px;
    text-align: center;
    max-width: 500px;
    width: 100%;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
    position: relative;
    color: white;
    animation: slideUp 0.3s ease;
    margin: auto;
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Close Button */
.apply-popup-close {
    position: absolute;
    top: 10px;
    right: 15px;
    background: rgba(45, 52, 54, 0.3);
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: white;
    padding: 4px 10px;
    border-radius: 50%;
    width: 35px;
    height: 35px;
    line-height: 24px;
    transition: all 0.3s;
}

.apply-popup-close:hover {
    background: rgba(45, 52, 54, 0.5);
    transform: rotate(90deg);
}

/* Popup Title */
.apply-popup-title {
    margin: 0 0 12px 0;
    font-size: 20px;
    font-weight: 600;
    padding-right: 30px;
}

.apply-popup-subtitle {
    font-size: 14px;
    margin: 0 0 20px 0;
    opacity: 0.95;
}

/* Timer */
.apply-popup-timer {
    font-size: 48px;
    font-weight: bold;
    margin: 20px 0;
    font-family: 'Courier New', monospace;
    text-shadow: 0 3px 6px rgba(0,0,0,0.3);
    animation: pulse 1s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* Progress Bar */
.apply-popup-progress-container {
    width: 100%;
    height: 6px;
    background-color: rgba(45, 52, 54, 0.3);
    border-radius: 3px;
    margin: 20px 0;
    overflow: hidden;
}

.apply-popup-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #2d3436, #636e72);
    border-radius: 3px;
    transition: width 1s linear;
    width: 100%;
    box-shadow: 0 0 8px rgba(45, 52, 54, 0.4);
}

/* Ad Section */
.apply-popup-ad {
    background: rgba(255, 255, 255, 0.98);
    border-radius: 8px;
    padding: 15px;
    margin: 20px 0;
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(122, 157, 143, 0.3);
    overflow: hidden;
    position: relative;
}

.apply-popup-ad::before {
    content: '📢 Advertisement';
    position: absolute;
    top: 5px;
    left: 10px;
    font-size: 11px;
    color: #636e72;
    opacity: 0.6;
}

.apply-popup-ad .adsbygoogle {
    display: block !important;
    width: 100%;
    min-height: 100px;
    max-height: 250px;
}

.apply-popup-ad-label {
    margin: 0;
    font-size: 13px;
    opacity: 0.7;
    color: #636e72;
}

.apply-popup-ad-note {
    margin: 4px 0 0 0;
    font-size: 11px;
    opacity: 0.5;
    color: #636e72;
}

/* Tip and Quote Boxes */
.apply-popup-tip,
.apply-popup-quote {
    background: rgba(45, 52, 54, 0.25);
    border-radius: 8px;
    padding: 15px;
    margin: 15px 0;
    text-align: left;
    border-left: 3px solid #2d3436;
    animation: slideIn 0.5s ease;
}

@keyframes slideIn {
    from {
        transform: translateX(-20px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.apply-popup-tip h4,
.apply-popup-quote h4 {
    margin: 0 0 8px 0;
    font-size: 14px;
    font-weight: 600;
}

.apply-popup-tip-text,
.apply-popup-quote-text {
    margin: 0;
    font-size: 13px;
    line-height: 1.5;
    opacity: 0.95;
}

.apply-popup-quote-text {
    font-style: italic;
}

/* Footer */
.apply-popup-footer {
    font-size: 12px;
    margin: 15px 0 0 0;
    opacity: 0.85;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .apply-button-box {
        padding: 20px 15px;
        border-radius: 10px;
    }
    
    .apply-button-box h3 {
        font-size: 18px;
    }
    
    .apply-button-box p {
        font-size: 13px;
        margin-bottom: 15px;
    }
    
    .apply-now-button {
        padding: 10px 28px;
        font-size: 14px;
        border-radius: 5px;
    }
    
    .apply-popup-overlay {
        padding: 10px;
    }
    
    .apply-popup-content {
        padding: 25px 18px;
        border-radius: 10px;
        max-width: 100%;
    }
    
    .apply-popup-close {
        top: 8px;
        right: 10px;
        width: 30px;
        height: 30px;
        font-size: 20px;
        line-height: 20px;
    }
    
    .apply-popup-title {
        font-size: 18px;
        margin-bottom: 10px;
        padding-right: 25px;
    }
    
    .apply-popup-subtitle {
        font-size: 13px;
        margin-bottom: 15px;
    }
    
    .apply-popup-timer {
        font-size: 40px;
        margin: 15px 0;
    }
    
    .apply-popup-progress-container {
        margin: 15px 0;
        height: 5px;
    }
    
    .apply-popup-ad {
        padding: 12px;
        margin: 15px 0;
        min-height: 60px;
    }
    
    .apply-popup-tip,
    .apply-popup-quote {
        padding: 12px;
        margin: 12px 0;
    }
    
    .apply-popup-tip h4,
    .apply-popup-quote h4 {
        font-size: 13px;
        margin-bottom: 6px;
    }
    
    .apply-popup-tip-text,
    .apply-popup-quote-text {
        font-size: 12px;
    }
    
    .apply-popup-footer {
        font-size: 11px;
        margin-top: 12px;
    }
    
    .apply-benefits-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .apply-benefit-card {
        padding: 12px;
    }
}

/* Tablet Responsive */
@media (min-width: 769px) and (max-width: 1024px) {
    .apply-button-box {
        padding: 22px 18px;
    }
    
    .apply-button-box h3 {
        font-size: 19px;
    }
    
    .apply-popup-content {
        max-width: 450px;
        padding: 28px 22px;
    }
    
    .apply-popup-timer {
        font-size: 44px;
    }
    
    .apply-benefits-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Small Mobile (320px - 480px) */
@media (max-width: 480px) {
    .apply-button-container {
        margin: 20px 0;
    }
    
    .apply-button-box {
        padding: 18px 12px;
    }
    
    .apply-button-box h3 {
        font-size: 16px;
        margin-bottom: 8px;
    }
    
    .apply-button-box p {
        font-size: 12px;
        margin-bottom: 12px;
    }
    
    .apply-now-button {
        padding: 9px 24px;
        font-size: 13px;
    }
    
    .apply-popup-content {
        padding: 20px 15px;
    }
    
    .apply-popup-title {
        font-size: 16px;
    }
    
    .apply-popup-subtitle {
        font-size: 12px;
    }
    
    .apply-popup-timer {
        font-size: 36px;
        margin: 12px 0;
    }
}

/* Large Desktop (1440px+) */
@media (min-width: 1440px) {
    .apply-button-box {
        max-width: 900px;
        margin-left: auto;
        margin-right: auto;
    }
    
    .apply-popup-content {
        max-width: 550px;
    }
}
