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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, 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: 20px;
}

header {
    text-align: center;
    padding: 40px 20px 20px;
    color: white;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

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

main {
    padding: 20px 0;
}

.upload-section {
    margin: 40px 0;
}

.drop-area {
    border: 3px dashed rgba(255, 255, 255, 0.5);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 60px 20px;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
}

.drop-area:hover,
.drop-area.dragover {
    border-color: white;
    background: rgba(255, 255, 255, 0.15);
}

.drop-content svg {
    color: white;
    margin-bottom: 20px;
}

.drop-content p {
    color: white;
    font-size: 1.1rem;
}

.browse-text {
    color: white;
    font-weight: bold;
    text-decoration: underline;
}

.preview-section {
    margin: 40px 0;
}

.image-comparison {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 30px;
}

@media (max-width: 768px) {
    .image-comparison {
        grid-template-columns: 1fr;
    }
}

.image-card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.image-card h3 {
    margin-bottom: 15px;
    color: #333;
    text-align: center;
}

.preview-container {
    width: 100%;
    min-height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    background:
        linear-gradient(45deg, #eee 25%, transparent 25%),
        linear-gradient(-45deg, #eee 25%, transparent 25%),
        linear-gradient(45deg, transparent 75%, #eee 75%),
        linear-gradient(-45deg, transparent 75%, #eee 75%);
    background-size: 20px 20px;
    background-position: 0 0, 0 10px, 10px -10px, -10px 0px;
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
}

.preview-container img {
    max-width: 100%;
    max-height: 400px;
    object-fit: contain;
}

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

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 10px;
}

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

.actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

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

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
    background: #2ecc71;
    color: white;
}

.btn-secondary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(46, 204, 113, 0.4);
}

.btn-tertiary {
    background: rgba(255, 255, 255, 0.8);
    color: #333;
    border: 1px solid #ddd;
}

.btn-tertiary:hover {
    background: white;
}

.features {
    margin: 60px 0;
    color: white;
}

.features h2 {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 40px;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.feature-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 25px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: transform 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
}

.feature-card h3 {
    margin-bottom: 10px;
    font-size: 1.2rem;
}

.feature-card p {
    opacity: 0.9;
}

.how-it-works {
    margin: 60px 0;
    color: white;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 40px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.how-it-works h2 {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 30px;
}

.how-it-works ol {
    max-width: 600px;
    margin: 0 auto;
    font-size: 1.1rem;
    line-height: 2;
}

footer {
    text-align: center;
    padding: 40px 20px;
    color: white;
    opacity: 0.8;
}

footer a {
    color: white;
    text-decoration: underline;
}

footer a:hover {
    opacity: 1;
}
