/* ═══════════════════════════════════════════════════════════════════════════
   EMAIL BUTTON & MODAL
   ═══════════════════════════════════════════════════════════════════════════ */

.hwc-email-section {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 12px;
    margin-top: 30px;
    text-align: center;
    border: 2px dashed #3498db;
}

.hwc-email-section h3 {
    margin: 0 0 10px 0;
    color: #2c3e50;
    font-size: 20px;
}

.hwc-email-section p {
    margin: 0 0 20px 0;
    color: #7f8c8d;
}

.hwc-btn-send-email {
    padding: 15px 40px;
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: #fff;
    border: none;
    border-radius: 50px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.4);
}

.hwc-btn-send-email:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(52, 152, 219, 0.6);
}

.hwc-btn-send-email:active {
    transform: translateY(0);
}

.hwc-btn-send-email .email-icon {
    font-size: 20px;
    margin-right: 8px;
}

/* Email Modal */
.hwc-email-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 10000;
    animation: fadeIn 0.3s;
}

.hwc-email-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.hwc-email-modal-content {
    background: #fff;
    border-radius: 16px;
    padding: 40px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hwc-email-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.hwc-email-modal-header h3 {
    margin: 0;
    color: #2c3e50;
    font-size: 24px;
}

.hwc-modal-close {
    background: transparent;
    border: none;
    font-size: 28px;
    color: #95a5a6;
    cursor: pointer;
    transition: all 0.3s;
    padding: 0;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.hwc-modal-close:hover {
    background: #f8f9fa;
    color: #e74c3c;
}

.hwc-email-modal-body {
    margin-bottom: 25px;
}

.hwc-form-group {
    margin-bottom: 20px;
}

.hwc-form-group label {
    display: block;
    margin-bottom: 8px;
    color: #2c3e50;
    font-weight: 600;
    font-size: 14px;
}

.hwc-form-group input[type="email"] {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e8e8e8;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.3s;
}

.hwc-form-group input[type="email"]:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.hwc-email-preview {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.hwc-email-preview h4 {
    margin: 0 0 10px 0;
    color: #2c3e50;
    font-size: 14px;
}

.hwc-email-preview-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #e8e8e8;
}

.hwc-email-preview-item:last-child {
    border-bottom: none;
}

.hwc-email-preview-label {
    color: #7f8c8d;
    font-size: 13px;
}

.hwc-email-preview-value {
    color: #2c3e50;
    font-weight: 600;
    font-size: 13px;
}

.hwc-email-modal-footer {
    display: flex;
    gap: 10px;
}

.hwc-btn-modal-cancel {
    flex: 1;
    padding: 12px;
    background: #e8e8e8;
    color: #2c3e50;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.hwc-btn-modal-cancel:hover {
    background: #d5d5d5;
}

.hwc-btn-modal-send {
    flex: 1;
    padding: 12px;
    background: linear-gradient(135deg, #27ae60 0%, #229954 100%);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.hwc-btn-modal-send:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(39, 174, 96, 0.4);
}

.hwc-btn-modal-send:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.hwc-sending-status {
    display: none;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 15px;
    background: #e3f2fd;
    border-radius: 8px;
    margin-top: 15px;
}

.hwc-sending-status.active {
    display: flex;
}

.hwc-sending-spinner {
    width: 20px;
    height: 20px;
    border: 3px solid #e8e8e8;
    border-top-color: #3498db;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.hwc-sending-text {
    color: #2980b9;
    font-weight: 600;
}

/* ═══════════════════════════════════════════════════════════════════════════
   ENHANCED MINDMAP VISUALIZATION
   ═══════════════════════════════════════════════════════════════════════════ */

.hwc-mindmap {
    padding: 30px 20px;
    position: relative;
    min-height: 400px;
}

.hwc-central-node {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    padding: 20px 35px;
    border-radius: 50px;
    text-align: center;
    font-weight: 700;
    font-size: 18px;
    margin: 0 auto 40px auto;
    max-width: 400px;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
    position: relative;
    z-index: 10;
}

.hwc-mindmap-branches {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    position: relative;
}

.hwc-branch {
    position: relative;
    animation: branchFadeIn 0.5s ease-out forwards;
    opacity: 0;
}

.hwc-branch:nth-child(1) { animation-delay: 0.1s; }
.hwc-branch:nth-child(2) { animation-delay: 0.2s; }
.hwc-branch:nth-child(3) { animation-delay: 0.3s; }
.hwc-branch:nth-child(4) { animation-delay: 0.4s; }

@keyframes branchFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hwc-branch-connector {
    position: absolute;
    top: -30px;
    left: 50%;
    width: 2px;
    height: 30px;
    background: linear-gradient(to bottom, #667eea, transparent);
    transform: translateX(-50%);
}

.hwc-branch-content {
    background: #fff;
    padding: 20px;
    border-radius: 12px;
    border: 2px solid #e8e8e8;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}

.hwc-branch-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(to bottom, #667eea, #764ba2);
}

.hwc-branch-content:hover {
    border-color: #667eea;
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.2);
    transform: translateY(-3px);
}

.hwc-branch-title {
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 15px;
    font-size: 16px;
    padding-left: 10px;
}

.hwc-subtopics {
    margin: 0;
    padding-left: 10px;
    list-style: none;
}

.hwc-subtopics li {
    margin-bottom: 10px;
    line-height: 1.5;
    font-size: 14px;
    color: #555;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    transition: all 0.3s;
    padding: 8px;
    border-radius: 6px;
}

.hwc-subtopics li:hover {
    background: #f8f9fa;
    color: #667eea;
}

.subtopic-dot {
    color: #667eea;
    font-size: 20px;
    flex-shrink: 0;
    line-height: 1;
}

/* Mindmap Screenshot Button */
.hwc-mindmap-actions {
    text-align: center;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 2px dashed #e8e8e8;
}

.hwc-btn-screenshot {
    padding: 10px 25px;
    background: #fff;
    color: #667eea;
    border: 2px solid #667eea;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.hwc-btn-screenshot:hover {
    background: #667eea;
    color: #fff;
}

/* ═══════════════════════════════════════════════════════════════════════════
   RESPONSIVE ADJUSTMENTS FOR EMAIL & MINDMAP
   ═══════════════════════════════════════════════════════════════════════════ */

@media (max-width: 768px) {
    .hwc-email-modal-content {
        padding: 25px;
    }
    
    .hwc-mindmap-branches {
        grid-template-columns: 1fr;
    }
    
    .hwc-central-node {
        font-size: 16px;
        padding: 15px 25px;
    }
}