* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: linear-gradient(#5383ff, #ff3555);
    --bg-color: #000000;
    --text-color: #ffffff;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.2;
    color: var(--text-color);
    background: linear-gradient(#000028, #000000);
    font-size:1rem;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

header {
    background: #111;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

nav {
    max-width: 1400px;
    margin: 0 auto;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 24px;
    display:flex;
    align-items:center;
    font-weight: bold;
    color: var(--primary-color);
}
.logo a {
    color: #ffffff; /*  */
    text-decoration: none;
}
.nav-links {
    display: flex;
    overflow-x: auto;
    gap: 20px;
}

.nav-links a {
    color: #fff;
    text-decoration: none;
    padding: 5px 10px;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.nav-links a:hover {
    color: var(--primary-color);
    background: #222;
}

.nav-links a.active {
    color: var(--primary-color);
    font-weight: 500;
}

h1 {
    font-size: 3.4rem;
    margin: 40px 0 20px;
    text-align: center;
    color: var(--text-color);
}

.description {
    text-align: center;
    color: #999;
    margin-bottom: 40px;
    font-size: 1.2rem;
}

.prompt-section {
    width:100%;
    max-width: 960px;
    margin: 0 auto;
}

.input-group {
    background: linear-gradient(#0d1323, #201f41);
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin: 40px 0;
}

.input-group input {
    width: 100%;
    padding: 20px;
    border: 2px solid #333;
    border-radius: 8px;
    font-size: 1.2rem;
    background: #222;
    color: #fff;
    transition: border-color 0.3s ease;
}


.input-group input:focus {
    border-color: var(--primary-color);
    outline: none;
}

.input-group button {
    width: 100%;
    padding: 20px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1.2rem;
    cursor: pointer;
    transition: background 0.3s ease;
}

.input-group button:hover {
    background: color(display-p3 0.2039 0.4706 0.9647);
}

#progressBar {
    margin: 30px 0;
    background: #222;
    border-radius: 8px;
    overflow: hidden;
}

.progress {
    width: 0;
    height: 4px;
    background: var(--primary-color);
    transition: width 0.3s ease;
}

.loading-text {
    text-align: center;
    color: #999;
}

h2 {
    font-size: 1.9rem;
    margin: 60px 0 30px;
    color: var(--text-color);
}

.gallery {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 25px;
    margin: 50px 0;
}

/* First row - 4 images */
.gallery-item:nth-child(-n+4) {
    grid-column: span 3;
    min-height: 300px;
}

/* Second row - 3 images */
.gallery-item:nth-child(n+5):nth-child(-n+7) {
    grid-column: span 4;
    min-height: 400px;
}


.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 16px;
    background: #111;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
    transition: transform 0.3s ease;
    text-decoration: none;
    grid-column: span 3;
    min-height: 250px;
}

.gallery-item:nth-child(8) {
    grid-column: span 6;
    min-height: 400px;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.gallery-item:hover {
    transform: translateY(-5px);
}

.gallery-item:hover img {
    transform: scale(1.05);
}

.image-title {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px;
    background: linear-gradient(transparent, rgba(0,0,0,0.9));
    color: white;
    font-size: 1rem;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gallery-item:hover .image-title {
    opacity: 1;
}

.similar-images {
    display: flex;
    flex-direction:column;
    margin: 40px auto;
    width:100%;
    max-width: 1200px;
}

.similar-item {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    background: #111;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
    transition: transform 0.3s ease;
    text-decoration: none;
    height: 300px;
    width: 100%;
}

.similar-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.similar-item:hover {
    transform: translateY(-5px);
}

.similar-item:hover img {
    transform: scale(1.05);
}

.similar-title {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px;
    background: linear-gradient(transparent, rgba(0,0,0,0.9));
    color: white;
    font-size: 1rem;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.similar-item:hover .similar-title {
    opacity: 1;
}

.prompt-stats {
    display: flex;
    align-items: center;
    gap: 15px;
    margin: 20px 0;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #999;
    font-size: .9rem;
}

.stat-item i {
    color: var(--primary-color);
    font-size: 1.1rem;
}

.like-count {
    font-weight: 500;
    color: #fff;
}

.prompt-actions {
    display: flex;
    gap: 20px;
    margin: 30px 0;
}

.action-button {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 8px;
    background: #222;
    border: none;
    color: #fff;
    cursor: pointer;
    transition: all 0.3s ease;
}

.action-button:hover {
    background: #333;
}

.action-button.liked {
    background: var(--primary-color);
}

.action-button i {
    font-size: 1.1rem;
}

.faq-section {
    margin: 80px auto;
    padding: 5px;
    background: linear-gradient(145deg, #111111, #1a1a1a);
    border-radius: 24px;
    box-shadow: 0 4px 30px rgba(0,0,0,0.3);
}

.faq-items {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 7px;
    margin-top: 40px;
}

.faq-item {
    background: rgba(255, 255, 255, 0.03);
    padding: 35px;
    border-radius: 16px;
    border-left: 4px solid var(--primary-color);
    border-right: 4px solid var(--primary-color);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.faq-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent, rgba(127, 61, 255, 0.05));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.faq-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.faq-item:hover::before {
    opacity: 1;
}

.faq-item h3 {
    font-size: 1.4rem;
    margin: 0 0 20px 0;
    color: var(--text-color);
    position: relative;
}

.faq-item p {
    margin: 0;
    color: #999;
    line-height: 1.4;
    font-size: 1.1rem;
    position: relative;
}

.faq-section h2 {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 20px;
    background: linear-gradient(45deg, var(--primary-color), #9b6dff);
    -webkit-background-clip: text;
}

.faq-section .description {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 40px;
    color: #999;
}

footer {
    background: #111;
    padding: 40px 0;
    margin-top: 80px;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    text-align: center;
    color: #999;
}

@media (max-width: 1200px) {
    .faq-items {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .gallery {
        grid-template-columns: repeat(6, 1fr);
    }
    
    .gallery-item:nth-child(-n+4) {
        grid-column: span 3;
    }
    
    .gallery-item:nth-child(n+5):nth-child(-n+7) {
        grid-column: span 2;
    }
    
    .gallery-item:nth-child(n+8):nth-child(-n+12) {
        grid-column: span 2;
    }
}

@media (max-width: 1024px){
    .container {
        padding: 15px;
    }

    .gallery {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

    .gallery-item:nth-child(n) {
        grid-column: span 1;
        min-height: 280px;
    }

    .input-group {
        padding: 25px;
    }

    .input-group input,
    .input-group button {
        font-size:2.1rem;
    }
    
    .nav-links a {
        font-size:1.5rem;
    }
    
    .faq-items {
        grid-template-columns: 1fr;
    }

    .faq-section {
        padding: 30px;
    }
    .prompt-content {
        grid-template-columns:unset !important;
    }
    .info-box *,.action-buttons button,.action-buttons a{
        font-size:1.1rem !important;
    }
    .prompt-info h1 {
        font-size:1.7rem !important;
    }
}

@media (max-width: 480px) {
    .gallery {
        grid-template-columns: 1fr;
    }

    .gallery-item:nth-child(n) {
        grid-column: span 1;
        min-height: 280px;
    }

    h1 {
        font-size: 1.5rem;
    }

    .description {
        font-size: 1.1rem;
    }

    .input-group {
        padding: 1.4rem;
    }

    .faq-section {
        padding: 1.4rem;
        margin: 40px auto;
    }
}
