/**
 * Mireng Community Public Styles
 */

/* Base Styles */
.mirengcomty-member-dashboard {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    line-height: 1.6;
    color: #333;
}

/* Dashboard Header */
.mirengcomty-dashboard-header {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 30px;
    align-items: center;
    margin-bottom: 40px;
    padding: 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    color: white;
}

.mirengcomty-welcome-section h1 {
    margin: 0 0 10px 0;
    font-size: 32px;
    font-weight: 700;
}

.mirengcomty-welcome-section p {
    margin: 0;
    font-size: 18px;
    opacity: 0.9;
}

/* Trust Score Card */
.mirengcomty-trust-score-card {
    display: flex;
    align-items: center;
    gap: 20px;
    background: rgba(255, 255, 255, 0.1);
    padding: 20px;
    border-radius: 8px;
    backdrop-filter: blur(10px);
}

.mirengcomty-score-circle {
    width: 80px;
    height: 80px;
}

.circular-chart {
    display: block;
    margin: 0 auto;
    max-width: 100%;
    max-height: 100%;
}

.circle-bg {
    fill: none;
    stroke: rgba(255, 255, 255, 0.2);
    stroke-width: 3.8;
}

.circle {
    fill: none;
    stroke-width: 2.8;
    stroke-linecap: round;
    animation: progress 1s ease-out forwards;
}

.percentage {
    fill: white;
    font-family: sans-serif;
    font-size: 16px;
    font-weight: 600;
    text-anchor: middle;
}

.mirengcomty-score-info h3 {
    margin: 0 0 5px 0;
    font-size: 18px;
    font-weight: 600;
}

.mirengcomty-score-info p {
    margin: 0;
    font-size: 14px;
    opacity: 0.8;
}

/* Dashboard Grid */
.mirengcomty-dashboard-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
    margin-bottom: 40px;
}

@media (max-width: 968px) {
    .mirengcomty-dashboard-grid {
        grid-template-columns: 1fr;
    }
}

/* Dashboard Sections */
.mirengcomty-dashboard-section {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    border: 1px solid #e1e5e9;
}

.mirengcomty-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f2f5;
}

.mirengcomty-section-header h2 {
    margin: 0;
    font-size: 24px;
    font-weight: 600;
    color: #1a1a1a;
}

.mirengcomty-section-date {
    font-size: 14px;
    color: #666;
    font-weight: 500;
}

/* Empty States */
.mirengcomty-empty-state {
    text-align: center;
    padding: 40px 20px;
    color: #666;
}

.mirengcomty-empty-icon {
    font-size: 48px;
    margin-bottom: 15px;
    opacity: 0.5;
}

.mirengcomty-empty-state h3 {
    margin: 0 0 10px 0;
    font-size: 18px;
    color: #333;
}

.mirengcomty-empty-state p {
    margin: 0;
    font-size: 14px;
}

/* Mission Cards */
.mirengcomty-missions-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.mirengcomty-mission-card {
    border: 2px solid #e1e5e9;
    border-radius: 10px;
    padding: 20px;
    background: #fafbfc;
    transition: all 0.3s ease;
}

.mirengcomty-mission-card:hover {
    border-color: #667eea;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.1);
}

.mirengcomty-mission-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.mirengcomty-mission-info h3 {
    margin: 0 0 5px 0;
    font-size: 18px;
    font-weight: 600;
    color: #1a1a1a;
}

.mirengcomty-mission-theme {
    margin: 0;
    font-size: 14px;
    color: #666;
    font-style: italic;
}

.mirengcomty-mission-status {
    flex-shrink: 0;
}

.mirengcomty-status-badge {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.mirengcomty-status-badge.active {
    background: #e7f5ff;
    color: #0066cc;
}

.mirengcomty-status-badge.completed {
    background: #e6f7e6;
    color: #006600;
}

.mirengcomty-status-badge.expired {
    background: #ffe6e6;
    color: #cc0000;
}

/* Mission Progress */
.mirengcomty-mission-progress {
    margin-bottom: 15px;
}

.mirengcomty-progress-bar {
    width: 100%;
    height: 8px;
    background: #e1e5e9;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 8px;
}

.mirengcomty-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    border-radius: 4px;
    transition: width 0.5s ease;
}

.mirengcomty-progress-text {
    font-size: 14px;
    color: #666;
    font-weight: 500;
}

/* Mission Details */
.mirengcomty-mission-details {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.mirengcomty-mission-stats {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.mirengcomty-stat {
    font-size: 13px;
    color: #666;
}

.mirengcomty-stat strong {
    color: #333;
}

.mirengcomty-mission-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.mirengcomty-mission-timer {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    background: #f0f2f5;
    border-radius: 6px;
    margin-top: 10px;
}

.mirengcomty-timer-display {
    font-family: 'Courier New', monospace;
    font-size: 18px;
    font-weight: 600;
    color: #1a1a1a;
    min-width: 60px;
}

/* Buttons */
.mirengcomty-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    line-height: 1.4;
}

.mirengcomty-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.mirengcomty-button-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.mirengcomty-button-primary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.mirengcomty-button-secondary {
    background: #f0f2f5;
    color: #333;
    border: 1px solid #d1d5db;
}

.mirengcomty-button-secondary:hover:not(:disabled) {
    background: #e1e5e9;
}

.mirengcomty-button-small {
    padding: 6px 12px;
    font-size: 12px;
}

/* Stats Grid */
.mirengcomty-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.mirengcomty-stat-card {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    border: 1px solid #e1e5e9;
    transition: transform 0.3s ease;
}

.mirengcomty-stat-card:hover {
    transform: translateY(-2px);
}

.mirengcomty-stat-icon {
    font-size: 24px;
    margin-bottom: 10px;
}

.mirengcomty-stat-content h3 {
    margin: 0 0 5px 0;
    font-size: 24px;
    font-weight: 700;
    color: #1a1a1a;
}

.mirengcomty-stat-content p {
    margin: 0;
    font-size: 12px;
    color: #666;
    text-transform: uppercase;
    font-weight: 500;
    letter-spacing: 0.5px;
}

/* Achievement Badge */
.mirengcomty-achievement-badge {
    display: flex;
    align-items: center;
    gap: 15px;
    background: linear-gradient(135deg, #ffd700 0%, #ffb347 100%);
    padding: 15px;
    border-radius: 8px;
    color: #333;
}

.mirengcomty-badge-icon {
    font-size: 32px;
}

.mirengcomty-badge-content h4 {
    margin: 0 0 5px 0;
    font-size: 16px;
    font-weight: 600;
}

.mirengcomty-badge-content p {
    margin: 0;
    font-size: 14px;
    opacity: 0.8;
}

/* Activity Timeline */
.mirengcomty-activity-timeline {
    position: relative;
}

.mirengcomty-activity-item {
    display: flex;
    gap: 15px;
    padding: 15px 0;
    border-bottom: 1px solid #f0f2f5;
}

.mirengcomty-activity-item:last-child {
    border-bottom: none;
}

.mirengcomty-activity-icon {
    width: 32px;
    height: 32px;
    background: #f0f2f5;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}

.mirengcomty-activity-content {
    flex: 1;
}

.mirengcomty-activity-title {
    font-weight: 500;
    color: #1a1a1a;
    margin-bottom: 4px;
}

.mirengcomty-activity-meta {
    font-size: 12px;
    color: #666;
}

/* Quick Actions */
.mirengcomty-quick-actions {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    border: 1px solid #e1e5e9;
}

.mirengcomty-quick-actions h2 {
    margin: 0 0 20px 0;
    font-size: 24px;
    font-weight: 600;
    color: #1a1a1a;
}

.mirengcomty-actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.mirengcomty-action-card {
    display: block;
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    text-decoration: none;
    color: #333;
    border: 1px solid #e1e5e9;
    transition: all 0.3s ease;
}

.mirengcomty-action-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border-color: #667eea;
    color: #667eea;
}

.mirengcomty-action-icon {
    font-size: 32px;
    margin-bottom: 15px;
}

.mirengcomty-action-card h3 {
    margin: 0 0 8px 0;
    font-size: 18px;
    font-weight: 600;
}

.mirengcomty-action-card p {
    margin: 0;
    font-size: 14px;
    color: #666;
}

/* Modals */
.mirengcomty-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.mirengcomty-modal-content {
    background: white;
    border-radius: 12px;
    padding: 0;
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.mirengcomty-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    border-bottom: 1px solid #e1e5e9;
}

.mirengcomty-modal-header h3 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: #1a1a1a;
}

.mirengcomty-modal-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #666;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.3s ease;
}

.mirengcomty-modal-close:hover {
    background: #f0f2f5;
}

.mirengcomty-modal-body {
    padding: 25px;
}

.mirengcomty-modal-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #e1e5e9;
}

/* Form Styles */
.mirengcomty-form-field {
    margin-bottom: 20px;
}

.mirengcomty-form-field label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #333;
}

.mirengcomty-form-field input,
.mirengcomty-form-field select,
.mirengcomty-form-field textarea {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.mirengcomty-form-field input:focus,
.mirengcomty-form-field select:focus,
.mirengcomty-form-field textarea:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* Notice Styles */
.mirengcomty-notice {
    background: #e7f5ff;
    border: 1px solid #b3d9ff;
    color: #0066cc;
    padding: 15px;
    border-radius: 6px;
    margin-bottom: 20px;
    text-align: center;
}

.mirengcomty-notice p {
    margin: 0 0 10px 0;
}

.mirengcomty-notice p:last-child {
    margin: 0;
}

/* Loading Spinner */
.mirengcomty-loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #667eea;
    border-radius: 50%;
    animation: mirengcomty-spin 1s linear infinite;
}

@keyframes mirengcomty-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes progress {
    0% { stroke-dasharray: 0 100; }
}

/* Responsive Design */
@media (max-width: 768px) {
    .mirengcomty-member-dashboard {
        padding: 15px;
    }
    
    .mirengcomty-dashboard-header {
        grid-template-columns: 1fr;
        gap: 20px;
        padding: 20px;
    }
    
    .mirengcomty-trust-score-card {
        justify-content: center;
        text-align: center;
    }
    
    .mirengcomty-welcome-section h1 {
        font-size: 24px;
    }
    
    .mirengcomty-welcome-section p {
        font-size: 16px;
    }
    
    .mirengcomty-dashboard-section {
        padding: 20px;
    }
    
    .mirengcomty-section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .mirengcomty-mission-details {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .mirengcomty-mission-stats {
        flex-direction: column;
        gap: 10px;
    }
    
    .mirengcomty-actions-grid {
        grid-template-columns: 1fr;
    }
    
    .mirengcomty-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .mirengcomty-modal-content {
        margin: 20px;
        max-height: calc(100vh - 40px);
    }
}

@media (max-width: 480px) {
    .mirengcomty-stats-grid {
        grid-template-columns: 1fr;
    }
    
    .mirengcomty-mission-actions {
        flex-direction: column;
        width: 100%;
    }
    
    .mirengcomty-button {
        width: 100%;
        justify-content: center;
    }
}
