:root {
    --primary-bg: #000000;
    --card-bg: #0f0f14f2;
    --accent: #6366f1;
    --border-color: #6366f133;
}

.gradient-preview {
    height: 150px;
    border-radius: 0.5rem;
    margin: 0.75rem 0;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.color-input {
    background: rgba(20, 20, 25, 0.9);
    border: 1px solid var(--border-color);
    border-radius: 0.4rem;
    color: white;
    padding: 0.4rem;
    width: 100px;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.color-input:focus {
    outline: none;
    border-color: var(--accent);
}
.infinite-gradients-head {
    padding: 1rem;
    border-radius: 0.5rem;
    overflow: hidden;
    background: #050505;
}
.infinite-gradients {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
    padding: 1rem;
    border-radius: 0.5rem;
    max-height: 500px;
    overflow: hidden;
    overflow-y: auto;
    background: #050505;
}

.infinite-gradients::-webkit-scrollbar {
    width: 6px;
}

.infinite-gradients::-webkit-scrollbar-track {
    background: transparent;
}

.infinite-gradients::-webkit-scrollbar-thumb {
    background: #6365f151;
    border-radius: 4px;
}

.gradient-item {
    height: 120px;
    padding: 0.1rem;
    border-radius: 0.5rem;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: transform 0.2s ease;
}

.gradient-item:hover {
    transform: scale(1.02);
}

.gradient-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: #000000b3;
    backdrop-filter: blur(4px);
    padding: 0.5rem;
    font-size: 0.85rem;
    border-radius: 0.5rem;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.gradient-item:hover .gradient-info {
    opacity: 1;
}

.btn {
    background: rgba(99, 102, 241, 0.1);
    color: var(--accent);
    border: 1px solid var(--border-color);
    padding: 0.4rem 0.8rem;
    border-radius: 0.4rem;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.9rem;
}

.btn:hover {
    background: var(--accent);
    color: white;
}

.alert {
    background: rgba(30, 58, 138, 0.3);
    border: 1px solid rgba(59, 130, 246, 0.2);
    animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.tools-section {
    padding: 4rem 0;
    position: sticky;
    top: 0;
    z-index: 10;
    backdrop-filter: blur(10px);
}

.color-picker {
    width: 35px;
    height: 35px;
    padding: 0;
    border: none;
    border-radius: 0.3rem;
    cursor: pointer;
}

.color-picker::-webkit-color-swatch-wrapper {
    padding: 0;
}

.color-picker::-webkit-color-swatch {
    border: none;
    border-radius: 0.3rem;
}

.notification {
    position: fixed;
    bottom: 1rem;
    right: 1rem;
    background: var(--accent);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 0.4rem;
    animation: slideIn 0.3s ease-out;
    z-index: 100;
}

@keyframes slideIn {
    from { transform: translateX(100%); }
    to { transform: translateX(0); }
}


.color-output {
    border-radius: 8px;
    padding: 0.25rem 0.95rem;
    margin-top: 16px;
    background: #050505;
    border: 1px solid var(--border-color);
}

.color-preview {
    width: 48px;
    height: 48px;
    border-radius: 6px;
    margin-left: 0.8rem;
    background: #323337;
}

.color-value {
    display: flex;
    align-items: center;
    background: var(--card-bg);
    padding: 4px 6px;
    border-radius: 6px;
    margin: 8px 0;
    font-size: 0.825rem;
}

.color-value span {
    flex-grow: 1;
    color: #c3ccd8;
}

.copy-btn {
    background: none;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    padding: 4px;
}

.copy-btn:hover {
    color: white;
}

canvas {
    margin: auto;
    max-height: 350px;
    max-width: 100%;
    border-radius: 0.3rem;
    border: dashed 2px #323337;
    background: #000000;
}

.image-upload-area {
    color: #e9e9e9;
    background: #050505;
    border: 1px solid var(--border-color);
    transition: 0.2s;
}
.image-upload-area:hover {
    color: #e9e9e9;
    background: #05060dbf;
    border: 1px solid var(--border-color);
    transition: 0.2s;
}