* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background: linear-gradient(135deg, #008080 0%, #004c4c 100%);
    color: #fff;
    min-height: 100vh;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.container {
    width: 100%;
    max-width: 1200px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

header {
    text-align: center;
    margin-bottom: 30px;
    width: 100%;
}

.logo {
    font-size: 3.5rem;
    color: #00e6e6;
    margin-bottom: 15px;
}

h1 {
    font-size: 2.8rem;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
}

.card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 30px;
    width: 100%;
    max-width: 800px;
    box-shadow: 0 8px 32px rgba(0, 79, 79, 0.3);
    margin-bottom: 30px;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 20px;
}

label {
    font-weight: 600;
    font-size: 1.1rem;
}

input {
    padding: 16px;
    border: none;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.9);
    font-size: 1rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

input:focus {
    outline: none;
    box-shadow: 0 4px 12px rgba(0, 230, 230, 0.4);
    transform: translateY(-2px);
}

.action-buttons {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.btn {
    padding: 16px 30px;
    border: none;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-primary {
    background: #00cccc;
    color: #004c4c;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
}

.btn-primary:hover {
    background: #00e6e6;
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.25);
}

.btn-primary:active {
    transform: translateY(0);
}

.error-message {
    color: #ff6b6b;
    margin-top: 15px;
    text-align: center;
    font-weight: 600;
    display: none;
}

.thumbnails-container {
    display: none;
    width: 100%;
    margin-top: 30px;
}

.thumbnails-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    width: 100%;
}

.thumbnail-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 79, 79, 0.3);
    transition: all 0.3s ease;
}

.thumbnail-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 40px rgba(0, 230, 230, 0.3);
}

.thumbnail-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-bottom: 2px solid #00cccc;
}

.thumbnail-details {
    padding: 20px;
}

.thumbnail-quality {
    font-weight: bold;
    font-size: 1.2rem;
    margin-bottom: 15px;
    color: #00e6e6;
}

.thumbnail-actions {
    display: flex;
    gap: 10px;
}

.btn-sm {
    padding: 10px 16px;
    font-size: 0.9rem;
}

.btn-secondary {
    background: #006666;
    color: #fff;
}

.btn-secondary:hover {
    background: #008080;
}

.loader {
    display: none;
    text-align: center;
    margin: 30px 0;
}

.loader-spinner {
    width: 50px;
    height: 50px;
    border: 5px solid rgba(0, 230, 230, 0.3);
    border-radius: 50%;
    border-top-color: #00e6e6;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

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

footer {
    margin-top: 40px;
    text-align: center;
    opacity: 0.8;
}

.instructions {
    margin-top: 25px;
    padding: 20px;
    background: rgba(0, 102, 102, 0.3);
    border-radius: 10px;
    width: 100%;
    max-width: 800px;
}

.instructions h3 {
    margin-bottom: 15px;
    color: #00e6e6;
}

.instructions ol {
    padding-left: 20px;
    text-align: left;
}

.instructions li {
    margin-bottom: 10px;
}

@media (max-width: 768px) {
    .action-buttons {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
    }
    
    h1 {
        font-size: 2.2rem;
    }
    
    .card {
        padding: 20px;
    }
}