/* ==========================================================================
   Demo Section Styles
   ========================================================================== */

/* Demo Section in Below-Fold */
.demo-section {
    margin-top: 2rem;
    text-align: center;
    padding: 2rem;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 12px;
    border: 1px solid #dee2e6;
}

.demo-section h3 {
    margin-bottom: 1rem;
    color: #495057;
    font-size: 1.25rem;
}

.demo-trigger-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 25px;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.demo-trigger-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

/* Demo Modal Styles */
.demo-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
    align-items: center;
    justify-content: center;
}

.demo-modal.show {
    display: flex;
    opacity: 1;
}

.demo-content {
    position: relative;
    background: white;
    border-radius: 12px;
    max-width: 800px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.demo-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid #e9ecef;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px 12px 0 0;
}

.demo-header h2 {
    margin: 0;
    color: white;
    font-size: 1.5rem;
}

.demo-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: white;
    padding: 0.5rem;
    border-radius: 50%;
    transition: background-color 0.2s;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.demo-close:hover {
    background-color: rgba(255, 255, 255, 0.3);
}

.demo-steps {
    padding: 2rem;
}

.demo-step {
    display: none;
}

.demo-step.active {
    display: block;
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.demo-step h3 {
    margin-bottom: 1.5rem;
    color: #495057;
    font-size: 1.5rem;
}

.demo-step p {
    color: #495057;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.demo-preview {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 1.5rem;
    margin: 1rem 0;
    min-height: 300px;
}

/* Demo Browse Styles */
.demo-browse .demo-search {
    margin-bottom: 1rem;
}

.demo-browse .demo-search input {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ced4da;
    border-radius: 6px;
    font-size: 1rem;
}

.demo-filters {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.demo-filter {
    padding: 0.5rem 1rem;
    background: #e9ecef;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.9rem;
    color: #495057;
}

.demo-filter.active {
    background: #667eea;
    color: white;
}

.demo-filter:hover {
    background: #dee2e6;
}

.demo-filter.active:hover {
    background: #5568d3;
}

.demo-prompt-card {
    background: white;
    padding: 1rem;
    border-radius: 6px;
    border: 1px solid #dee2e6;
    margin-bottom: 1rem;
}

.demo-prompt-card p {
    margin: 0 0 0.75rem 0;
    color: #495057;
    line-height: 1.6;
}

.demo-tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.demo-tags .tag {
    background: #e9ecef;
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    font-size: 0.8rem;
    color: #495057;
}

/* Demo Write Styles */
.demo-write .demo-toolbar {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.demo-tool-btn {
    padding: 0.5rem 0.75rem;
    border: 1px solid #ced4da;
    background: white;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.2s;
}

.demo-tool-btn:hover {
    background: #f8f9fa;
    border-color: #adb5bd;
}

.demo-editor textarea {
    width: 100%;
    height: 150px;
    border: 1px solid #ced4da;
    border-radius: 6px;
    padding: 1rem;
    font-family: inherit;
    font-size: 1rem;
    resize: vertical;
    line-height: 1.6;
}

.demo-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #e9ecef;
    font-size: 0.9rem;
    color: #6c757d;
}

.demo-word-count {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.demo-save-status {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    color: #28a745;
}

/* Demo Educator Styles */
.demo-educator .demo-tabs {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    border-bottom: 2px solid #e9ecef;
}

.demo-tab {
    padding: 0.75rem 1rem;
    background: transparent;
    border: none;
    cursor: pointer;
    color: #6c757d;
    font-weight: 500;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: all 0.2s;
}

.demo-tab.active {
    color: #667eea;
    border-bottom-color: #667eea;
}

.demo-tab:hover {
    color: #495057;
}

.demo-form textarea {
    width: 100%;
    height: 100px;
    border: 1px solid #ced4da;
    border-radius: 6px;
    padding: 1rem;
    margin-bottom: 1rem;
    font-family: inherit;
    font-size: 1rem;
    resize: vertical;
}

.demo-form-row {
    display: flex;
    gap: 1rem;
}

.demo-form-row select {
    flex: 1;
    padding: 0.75rem;
    border: 1px solid #ced4da;
    border-radius: 6px;
    font-size: 1rem;
    background: white;
}

/* Demo Controls */
.demo-controls {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.5rem;
    border-top: 1px solid #e9ecef;
    background: #f8f9fa;
    border-radius: 0 0 12px 12px;
}

.demo-prev, .demo-next, .demo-skip {
    padding: 0.75rem 1.5rem;
    border: 1px solid #ced4da;
    background: white;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 1rem;
    font-weight: 500;
}

.demo-prev {
    color: #6c757d;
}

.demo-next {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

.demo-skip {
    color: #6c757d;
}

.demo-prev:hover, .demo-skip:hover {
    background: #f8f9fa;
    border-color: #adb5bd;
}

.demo-next:hover {
    background: #5568d3;
    border-color: #5568d3;
}

.demo-prev:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Progress Indicator */
.demo-progress {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem;
}

.demo-progress-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #dee2e6;
    transition: all 0.3s;
}

.demo-progress-dot.active {
    background: #667eea;
    transform: scale(1.2);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .demo-content {
        width: 95%;
        margin: 1rem;
        max-height: 90vh;
    }
    
    .demo-steps {
        padding: 1rem;
    }
    
    .demo-header {
        padding: 1rem;
    }
    
    .demo-header h2 {
        font-size: 1.25rem;
    }
    
    .demo-preview {
        padding: 1rem;
        min-height: 250px;
    }
    
    .demo-controls {
        flex-direction: column;
        gap: 0.5rem;
        padding: 1rem;
    }
    
    .demo-controls button {
        width: 100%;
    }
    
    .demo-form-row {
        flex-direction: column;
    }
    
    .demo-section {
        padding: 1.5rem 1rem;
    }
}

@media (max-width: 480px) {
    .demo-step h3 {
        font-size: 1.25rem;
    }
    
    .demo-trigger-btn {
        font-size: 1rem;
        padding: 10px 20px;
    }
}

