/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header Styles */
.header {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    color: white;
    padding: 3rem 0;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    font-weight: 700;
}

.header h1 i {
    margin-right: 0.5rem;
    color: #3498db;
}

.subtitle {
    font-size: 1.1rem;
    opacity: 0.9;
    font-weight: 300;
    margin-bottom: 1rem;
}

.header-actions {
    margin-top: 1rem;
}

.instructions-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    text-decoration: none;
    padding: 0.6rem 1.2rem;
    border-radius: 25px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.instructions-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

/* Main Content */
.main {
    padding: 2rem 0;
}

/* Controls Section */
.controls {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.search-section {
    margin-bottom: 1.5rem;
}

.search-box {
    position: relative;
    max-width: 500px;
    margin: 0 auto;
}

.search-box i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #666;
}

.search-box input {
    width: 100%;
    padding: 0.8rem 1rem 0.8rem 3rem;
    border: 2px solid #e1e8ed;
    border-radius: 50px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.search-box input:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.filter-section {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.filter-group label {
    font-weight: 600;
    color: #555;
    font-size: 0.9rem;
}

.filter-group select {
    padding: 0.6rem 1rem;
    border: 2px solid #e1e8ed;
    border-radius: 8px;
    font-size: 0.9rem;
    background: white;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-group select:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

/* Results Counter */
.results-counter {
    text-align: center;
    margin: 1rem 0;
    color: #666;
    font-size: 0.9rem;
}

/* Prompts Grid */
.prompts-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin-bottom: 2rem;
}

@media (max-width: 768px) {
    .prompts-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

.prompt-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    cursor: pointer;
    display: flex;
    flex-direction: column;
}

.prompt-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 45px rgba(0, 0, 0, 0.15);
}

.prompt-header {
    padding: 1.5rem 1.5rem 0 1.5rem;
}

.prompt-images {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    padding: 1rem 1.5rem;
}

.prompt-images img {
    width: 100%;
    aspect-ratio: 4/3;
    object-fit: cover;
    border-radius: 8px;
    transition: transform 0.3s ease;
    border: 2px solid #e9ecef;
}

.prompt-card:hover .prompt-images img {
    transform: scale(1.02);
}

.image-label {
    font-size: 0.7rem;
    text-align: center;
    color: #666;
    margin-top: 0.3rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, rgba(52, 152, 219, 0.9), rgba(155, 89, 182, 0.9));
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    border-radius: 8px;
}

.prompt-images:hover .image-overlay {
    opacity: 1;
}

.view-prompt-btn {
    background: white;
    color: #333;
    border: none;
    padding: 0.6rem 1.2rem;
    border-radius: 20px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.view-prompt-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.prompt-content {
    padding: 0 1.5rem 1.5rem 1.5rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.prompt-header {
    margin-bottom: 1rem;
}

.prompt-label {
    font-size: 1.2rem;
    font-weight: 700;
    color: #2c3e50;
    margin: 0 0 0.5rem 0;
}

.prompt-tool {
    display: inline-block;
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.tool-midjourney { background: #ff6b6b; color: white; }
.tool-dalle { background: #4ecdc4; color: white; }
.tool-gemini { background: #45b7d1; color: white; }
.tool-chatgpt { background: #96ceb4; color: white; }

.prompt-text-container {
    margin-bottom: 1rem;
    flex: 1;
}

.prompt-preview {
    color: #666;
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 0.5rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: all 0.3s ease;
}

.prompt-full {
    color: #666;
    font-size: 0.9rem;
    line-height: 1.5;
    display: none;
}

.prompt-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.expand-btn, .copy-btn {
    background: #3498db;
    color: white;
    border: none;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.3rem;
    flex: 1;
    justify-content: center;
}

.expand-btn:hover, .copy-btn:hover {
    background: #2980b9;
    transform: translateY(-1px);
}

.copy-btn.copied {
    background: #27ae60;
}

.prompt-date {
    font-size: 0.8rem;
    color: #999;
    text-align: right;
    margin-top: auto;
}

/* Loading and No Results */
.loading, .no-results {
    text-align: center;
    padding: 3rem;
    color: white;
}

.loading i {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.no-results i {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.7;
}

.no-results h3 {
    margin-bottom: 0.5rem;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
}

.modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: white;
    border-radius: 20px;
    width: 90%;
    max-width: 1000px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-header {
    padding: 2rem;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    color: #2c3e50;
    margin: 0;
}

.close-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #666;
    padding: 0.5rem;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.close-btn:hover {
    background: #f8f9fa;
    color: #333;
}

.modal-body {
    padding: 2rem;
}

.image-comparison {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

.image-container {
    text-align: center;
}

.image-container h3 {
    margin-bottom: 1rem;
    color: #555;
    font-size: 1.1rem;
}

.image-container img {
    width: 100%;
    max-width: 500px;
    height: 375px;
    object-fit: cover;
    border-radius: 10px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.prompt-details {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 2rem;
}

.prompt-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.tool-badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.date-added {
    color: #666;
    font-size: 0.9rem;
}

.prompt-text-section h3 {
    margin-bottom: 1rem;
    color: #333;
}

.prompt-text {
    background: white;
    padding: 1.5rem;
    border-radius: 10px;
    border-left: 4px solid #3498db;
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    white-space: pre-wrap;
}

.copy-btn {
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 25px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.copy-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(52, 152, 219, 0.3);
}

.copy-btn:active {
    transform: translateY(0);
}

.copy-btn.copied {
    background: linear-gradient(135deg, #27ae60, #229954);
}

/* Responsive Design */
@media (max-width: 768px) {
    .header h1 {
        font-size: 2rem;
    }

    .subtitle {
        font-size: 1rem;
    }

    .instructions-btn {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }

    .controls {
        padding: 1.5rem;
    }

    .filter-section {
        flex-direction: column;
        gap: 1rem;
    }

    .prompts-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .prompt-images {
        grid-template-columns: 1fr;
        gap: 0.5rem;
        padding: 0.5rem 1rem;
    }

    .prompt-images img {
        aspect-ratio: 4/3;
    }

    .prompt-header {
        padding: 1rem 1rem 0 1rem;
    }

    .prompt-content {
        padding: 0 1rem 1rem 1rem;
    }

    .prompt-actions {
        flex-direction: column;
        gap: 0.5rem;
    }

    .expand-btn, .copy-btn {
        width: 100%;
        justify-content: center;
    }

    .image-comparison {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .image-container img {
        max-width: 100%;
        height: 250px;
    }

    .modal-content {
        margin: 1rem;
        width: calc(100% - 2rem);
    }

    .modal-header, .modal-body {
        padding: 1.5rem;
    }

    .prompt-meta {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }

    .header {
        padding: 2rem 0;
    }

    .header h1 {
        font-size: 1.8rem;
    }

    .controls {
        padding: 1rem;
    }

    .prompt-content {
        padding: 1rem;
    }

    .modal-header, .modal-body {
        padding: 1rem;
    }
}

/* Utility Classes */
.hidden {
    display: none !important;
}

.fade-in {
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #5a6fd8, #6a4190);
}

/* Footer Styles */
.footer {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    color: white;
    padding: 3rem 0 1rem 0;
    margin-top: 4rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: #3498db;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: #bdc3c7;
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.footer-links a:hover {
    color: #3498db;
    padding-left: 0.5rem;
}

.footer-bottom {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-info h4 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: #3498db;
}

.footer-info p {
    color: #bdc3c7;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.footer-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag {
    background: rgba(52, 152, 219, 0.2);
    color: #3498db;
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid rgba(52, 152, 219, 0.3);
}

.footer-contact h4 {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: #3498db;
}

.search-terms {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.search-terms a {
    color: #bdc3c7;
    text-decoration: none;
    font-size: 0.85rem;
    padding: 0.3rem 0.6rem;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.search-terms a:hover {
    background: rgba(52, 152, 219, 0.2);
    color: #3498db;
    border-color: rgba(52, 152, 219, 0.4);
}

.footer-copyright {
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
    color: #95a5a6;
    font-size: 0.85rem;
}

.footer-copyright a {
    color: #3498db;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-copyright a:hover {
    color: #2980b9;
}

.disclaimer {
    margin-top: 0.5rem;
    font-size: 0.8rem;
    opacity: 0.8;
}

/* Responsive Footer */
@media (max-width: 768px) {
    .footer-content {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 1.5rem;
    }

    .footer-bottom {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .footer-tags {
        justify-content: center;
    }

    .search-terms {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .footer {
        padding: 2rem 0 1rem 0;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .footer-section h3 {
        font-size: 1.1rem;
    }

    .footer-info h4,
    .footer-contact h4 {
        font-size: 1.1rem;
    }
}