/*
 * EPC MODAL STYLES
 * Handles Energy Performance Certificate requirement modal
 * Used on property listing pages
 * Last updated: 04/12/2025
 */

/* ========================================
   BASE MODAL OVERLAY
   ======================================== */
.epc-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: epcFadeIn 0.3s ease;
}

@keyframes epcFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* ========================================
   MAIN MODAL CONTAINER
   ======================================== */
.epc-modal {
    background: white;
    padding: 40px;
    border-radius: 15px;
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    text-align: center;
    animation: epcSlideUp 0.4s ease;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

@keyframes epcSlideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.epc-modal h2 {
    color: #1B2B4B;
    font-size: 1.8rem;
    margin-bottom: 15px;
    font-weight: 600;
}

.epc-modal p {
    color: #666;
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 20px;
}

/* ========================================
   EPC ICON
   ======================================== */
.epc-icon {
    font-size: 64px;
    color: #28a745;
    margin-bottom: 20px;
}

/* ========================================
   INFO BOX
   ======================================== */
.epc-info-box {
    background: #f8f9fa;
    border-left: 4px solid #17a2b8;
    padding: 15px;
    margin: 20px 0;
    text-align: left;
    border-radius: 5px;
}

.epc-info-box i {
    color: #17a2b8;
    margin-right: 8px;
    font-size: 1.2rem;
}

.epc-info-box p {
    margin: 0;
    color: #495057;
    font-size: 0.95rem;
}

/* ========================================
   OPTIONS CONTAINER
   ======================================== */
.epc-options {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin: 30px 0;
}

/* ========================================
   EPC BUTTONS
   ======================================== */
.epc-btn {
    padding: 20px 30px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    text-align: left;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    gap: 8px;
    font-size: 1rem;
    font-weight: 600;
}

.epc-btn:hover {
    transform: translateY(-2px);
}

.epc-btn i {
    font-size: 24px;
    margin-bottom: 5px;
}

.epc-btn-subtitle {
    font-size: 0.9rem;
    opacity: 0.9;
    font-weight: 400;
}

/* Primary Button - Get EPC Now */
.epc-btn.primary {
    background: linear-gradient(135deg, #1B2B4B, #2c3e50);
    color: white;
}

.epc-btn.primary:hover {
    box-shadow: 0 5px 20px rgba(27, 43, 75, 0.4);
}

/* Secondary Button - I Have EPC */
.epc-btn.secondary {
    background: #28a745;
    color: white;
}

.epc-btn.secondary:hover {
    background: #218838;
}

/* ========================================
   DRAFT NOTICE
   ======================================== */
.epc-draft-notice {
    background: #fff3cd;
    border: 1px solid #ffc107;
    padding: 15px;
    border-radius: 8px;
    margin-top: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    text-align: left;
}

.epc-draft-notice i {
    color: #856404;
    font-size: 1.2rem;
}

.epc-draft-notice p {
    margin: 0;
    color: #856404;
    font-size: 0.95rem;
}

/* ========================================
   UPLOAD OPTIONS MODAL
   ======================================== */
.epc-modal.upload-options {
    max-width: 700px;
}

.upload-option-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin: 30px 0;
}

.upload-card {
    background: #f8f9fa;
    padding: 30px 20px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    text-align: center;
}

.upload-card:hover {
    border-color: #1B2B4B;
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.upload-card i {
    font-size: 48px;
    color: #1B2B4B;
    margin-bottom: 15px;
}

.upload-card h3 {
    color: #1B2B4B;
    font-size: 1.3rem;
    margin-bottom: 10px;
}

.upload-card p {
    color: #666;
    font-size: 0.95rem;
    margin-bottom: 15px;
}

.card-btn {
    margin-top: 15px;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.card-btn.primary {
    background: #1B2B4B;
    color: white;
}

.card-btn.primary:hover {
    background: #2c3e50;
}

.card-btn.secondary {
    background: #6c757d;
    color: white;
}

.card-btn.secondary:hover {
    background: #5a6268;
}

/* ========================================
   EPC HELP LINK
   ======================================== */
.epc-help {
    margin-top: 20px;
    padding: 15px;
    background: #e7f3ff;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.epc-help i {
    color: #0066cc;
    font-size: 1.2rem;
}

.epc-help a {
    color: #0066cc;
    text-decoration: none;
    font-weight: 500;
}

.epc-help a:hover {
    text-decoration: underline;
}

/* ========================================
   FILE UPLOAD FORM
   ======================================== */
.epc-modal.upload-form {
    max-width: 550px;
}

.file-upload-area {
    border: 3px dashed #dee2e6;
    border-radius: 10px;
    padding: 40px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    margin: 20px 0;
}

.file-upload-area:hover {
    border-color: #1B2B4B;
    background: #f8f9fa;
}

.file-upload-area i {
    font-size: 64px;
    color: #6c757d;
    margin-bottom: 20px;
    display: block;
}

.file-upload-area p {
    color: #495057;
    font-size: 1rem;
    margin-bottom: 15px;
}

.upload-trigger-btn {
    background: #1B2B4B;
    color: white;
    padding: 12px 30px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.upload-trigger-btn:hover {
    background: #2c3e50;
    transform: translateY(-2px);
}

/* File selected state */
.file-upload-area.file-selected {
    border-color: #28a745;
    background: #f0f9f0;
}

.file-upload-area.file-selected i {
    color: #28a745;
}

/* ========================================
   UPLOAD INFO
   ======================================== */
.upload-info {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    margin: 20px 0;
}

.upload-info p {
    margin: 5px 0;
    font-size: 0.9rem;
    color: #666;
}

.upload-info strong {
    color: #333;
}

/* ========================================
   UPLOAD ACTIONS
   ======================================== */
.upload-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 30px;
}

.action-btn {
    padding: 12px 30px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.action-btn.primary {
    background: #1B2B4B;
    color: white;
}

.action-btn.primary:hover {
    background: #2c3e50;
    transform: translateY(-2px);
}

.action-btn.primary:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

.action-btn.secondary {
    background: #6c757d;
    color: white;
}

.action-btn.secondary:hover {
    background: #5a6268;
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */
@media (max-width: 768px) {
    .epc-modal {
        padding: 30px 20px;
        width: 95%;
    }

    .epc-modal h2 {
        font-size: 1.5rem;
    }

    .upload-option-cards {
        grid-template-columns: 1fr;
    }

    .epc-options {
        gap: 12px;
    }

    .epc-btn {
        padding: 15px 20px;
    }

    .file-upload-area {
        padding: 30px 15px;
    }

    .upload-actions {
        flex-direction: column;
    }

    .action-btn {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .epc-icon {
        font-size: 48px;
    }

    .epc-modal h2 {
        font-size: 1.3rem;
    }

    .epc-btn i {
        font-size: 20px;
    }

    .upload-card i {
        font-size: 36px;
    }
}