* {
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    color: #fff;
    min-height: 100vh;
    padding: 20px;
}

main {
    max-width: 600px;
    margin: 2em auto;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(15px);
    padding: 2em;
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

h2 {
    text-align: center;
    margin-bottom: 1.5em;
    font-size: 1.8em;
    font-weight: 300;
}

.field {
    margin-bottom: 1.5em;
}

label {
    display: block;
    margin-bottom: 0.5em;
    font-weight: 500;
    font-size: 0.9em;
    opacity: 0.9;
}

input,
select,
button {
    width: 100%;
    padding: 12px 16px;
    border: none;
    border-radius: 12px;
    font-size: 1em;
    transition: all 0.3s ease;
}

input,
select {
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    border: 2px solid transparent;
}

input:focus,
select:focus {
    outline: none;
    background: rgba(255, 255, 255, 1);
    border-color: #4a90e2;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(74, 144, 226, 0.4);
}

button {
    background: linear-gradient(45deg, #2c3e50, #4a90e2);
    color: white;
    cursor: pointer;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 1em;
    border: none;
}

button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(74, 144, 226, 0.5);
}

button:active {
    transform: translateY(0);
}

button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.status {
    padding: 12px 16px;
    border-radius: 12px;
    margin: 1em 0;
    font-weight: 500;
    text-align: center;
    animation: fadeIn 0.3s ease;
}

.status.info {
    background: rgba(74, 144, 226, 0.2);
    border: 1px solid rgba(74, 144, 226, 0.5);
    color: #4a90e2;
}

.status.ok {
    background: rgba(39, 174, 96, 0.2);
    border: 1px solid rgba(39, 174, 96, 0.5);
    color: #27ae60;
}

.status.error {
    background: rgba(192, 57, 43, 0.2);
    border: 1px solid rgba(192, 57, 43, 0.5);
    color: #c0392b;
}

#meta {
    background: rgba(255, 255, 255, 0.03);
    padding: 1.5em;
    border-radius: 16px;
    margin-top: 1.5em;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

#title {
    font-size: 1.2em;
    font-weight: 600;
    margin-bottom: 1em;
    color: #fff;
}

#thumb {
    width: 100%;
    max-width: 300px;
    height: auto;
    border-radius: 12px;
    margin: 1em 0;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.range {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.range input {
    margin-top: 0;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 600px) {
    main {
        margin: 1em;
        padding: 1.5em;
    }

    .range {
        grid-template-columns: 1fr;
        gap: 8px;
    }
}

.loading {
    position: relative;
    overflow: hidden;
}

.loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% {
        left: -100%;
    }

    100% {
        left: 100%;
    }
}