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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.container {
    max-width: 800px;
    width: 100%;
}

.header {
    text-align: center;
    margin-bottom: 40px;
    color: white;
}

.header .logo {
    max-width: 450px;
    max-height: 120px;
    width: auto;
    height: auto;
    object-fit: contain;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
    transition: transform 0.3s ease;
}

.header .logo:hover {
    transform: scale(1.02);
}

.header h1 {
    font-size: 3em;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

.subtitle {
    font-size: 1.2em;
    opacity: 0.9;
}

.search-container {
    margin-bottom: 30px;
}

.search-box {
    display: flex;
    gap: 10px;
    background: white;
    padding: 10px;
    border-radius: 50px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
}

.search-box:hover,
.search-box:focus-within {
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.3);
    transform: translateY(-2px);
}

#searchInput {
    flex: 1;
    border: none;
    outline: none;
    font-size: 16px;
    padding: 15px 20px;
    background: transparent;
}

#searchInput::placeholder {
    color: #999;
}

.search-button {
    display: flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.search-button:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 20px rgba(102, 126, 234, 0.4);
}

.search-button:active {
    transform: scale(0.98);
}

.loading {
    text-align: center;
    color: white;
    margin: 40px 0;
}

.spinner {
    width: 50px;
    height: 50px;
    margin: 0 auto 20px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top: 4px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

.results {
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    animation: fadeIn 0.5s ease;
}

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

.result-header {
    margin-bottom: 25px;
    padding-bottom: 20px;
    border-bottom: 2px solid #f0f0f0;
}

.result-header-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
    flex-wrap: wrap;
}

.download-button {
    display: flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
    white-space: nowrap;
}

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

.download-button:active {
    transform: translateY(0);
}

.result-title {
    font-size: 1.8em;
    color: #333;
    margin-bottom: 10px;
}

.result-count {
    color: #667eea;
    font-size: 0.95em;
    font-weight: 500;
}

.result-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.result-item {
    display: flex;
    gap: 20px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 12px;
    transition: all 0.3s ease;
    border-left: 4px solid #667eea;
}

.result-item:hover {
    background: #f0f1f3;
    transform: translateX(5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.item-code {
    flex-shrink: 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 12px 18px;
    border-radius: 8px;
    font-weight: bold;
    font-size: 1.1em;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 80px;
    height: fit-content;
}

.item-content {
    flex: 1;
}

.item-title {
    font-size: 1.2em;
    color: #333;
    margin-bottom: 8px;
    font-weight: 600;
}

.item-description {
    color: #666;
    line-height: 1.6;
    font-size: 0.95em;
}

.error {
    background: white;
    border-radius: 20px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    animation: fadeIn 0.5s ease;
}

.error-icon {
    font-size: 3em;
    margin-bottom: 15px;
}

.error-message {
    font-size: 1.2em;
    color: #e74c3c;
    margin-bottom: 10px;
}

.error-details {
    font-size: 0.9em;
    color: #999;
}

.footer {
    margin-top: 30px;
    text-align: center;
    color: white;
}

.footer p {
    margin: 10px 0;
    opacity: 0.9;
}

.example {
    cursor: pointer;
    padding: 5px 10px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 15px;
    margin: 0 5px;
    transition: all 0.3s ease;
    display: inline-block;
}

.example:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

.info {
    font-size: 0.9em;
    opacity: 0.7;
}

.copyright {
    font-size: 0.85em;
    opacity: 0.8;
    margin-top: 5px;
    font-weight: 500;
}

/* Responsive */
@media (max-width: 768px) {
    .header .logo {
        max-width: 300px;
        max-height: 80px;
    }
    
    .header h1 {
        font-size: 2em;
    }
    
    .search-box {
        flex-direction: column;
        border-radius: 20px;
    }
    
    .search-button {
        justify-content: center;
        border-radius: 15px;
    }
    
    .result-title {
        font-size: 1.5em;
    }
}
