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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: #1a1a1a;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    position: relative;
    overflow-x: hidden;
}

.code-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    font-family: 'Fira Code', 'Courier New', monospace;
    font-size: 11px;
    line-height: 1.5;
    padding: 25px 30px;
    opacity: 0.12;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
    color: #4a4a4a;
    column-count: 3;
    column-gap: 40px;
    column-fill: auto;
}

@media (max-width: 1400px) {
    .code-background {
        column-count: 2;
    }
}

@media (max-width: 900px) {
    .code-background {
        column-count: 1;
        font-size: 10px;
    }
}

.container {
    position: relative;
    z-index: 1;
}

.container {
    background: rgba(42, 42, 42, 0.95);
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    padding: 40px;
    max-width: 600px;
    width: 100%;
    backdrop-filter: blur(10px);
}


.header {
    text-align: center;
    margin-bottom: 30px;
}

.header h1 {
    color: #ffffff;
    font-size: 2.5em;
    margin-bottom: 10px;
}

.header p {
    color: #a0a0a0;
    font-size: 1.1em;
}

.input-section {
    margin-bottom: 30px;
}

.input-group {
    margin-bottom: 20px;
}

.input-group label,
.size-selector label {
    display: block;
    margin-bottom: 8px;
    color: #e0e0e0;
    font-weight: 600;
    font-size: 0.95em;
}

#url-input {
    width: 100%;
    padding: 15px;
    font-size: 1em;
    border: 2px solid #404040;
    border-radius: 6px;
    transition: all 0.3s ease;
    outline: none;
    background: #1a1a1a;
    color: #ffffff;
}

#url-input:focus {
    border-color: #4A90E2;
    box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.2);
}

.size-selector {
    margin-bottom: 20px;
}

.image-upload {
    margin-bottom: 20px;
}

.upload-container {
    display: flex;
    align-items: center;
    gap: 10px;
}

.btn-upload {
    padding: 10px 20px;
    font-size: 0.95em;
    font-weight: 600;
    border: 2px solid #404040;
    border-radius: 6px;
    background: #1a1a1a;
    color: #ffffff;
    cursor: pointer;
    transition: all 0.2s ease;
    outline: none;
}

.btn-upload:hover {
    border-color: #4A90E2;
    background: #2a2a2a;
}

.file-name {
    color: #a0a0a0;
    font-size: 0.9em;
    flex: 1;
}

.btn-clear {
    padding: 8px 16px;
    font-size: 0.9em;
    font-weight: 600;
    border: none;
    border-radius: 6px;
    background: #dc3545;
    color: white;
    cursor: pointer;
    transition: background 0.2s ease;
    outline: none;
}

.btn-clear:hover {
    background: #c82333;
}

#qr-size {
    width: 100%;
    padding: 15px;
    font-size: 1em;
    border: 2px solid #404040;
    border-radius: 6px;
    background: #1a1a1a;
    color: #ffffff;
    cursor: pointer;
    transition: all 0.3s ease;
    outline: none;
}

#qr-size:focus {
    border-color: #4A90E2;
}

.btn-generate {
    width: 100%;
    padding: 15px;
    font-size: 1.1em;
    font-weight: 600;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s ease;
    outline: none;
    background: #4A90E2;
    color: white;
    margin-top: 10px;
}

.btn-generate:hover {
    background: #357ABD;
}

.btn-generate:active {
    background: #2868A8;
}

.btn-generate:disabled {
    background: #555555;
    cursor: not-allowed;
}

.github-link {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 48px;
    height: 48px;
    background: #2a2a2a;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    text-decoration: none;
    transition: all 0.2s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.github-link:hover {
    background: #3a3a3a;
    transform: scale(1.1);
}

.github-link svg {
    width: 28px;
    height: 28px;
}

.footer {
    text-align: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #e0e0e0;
}

.footer p {
    color: #666;
    font-size: 0.9em;
}

@media (max-width: 600px) {
    .container {
        padding: 25px;
    }

    .header h1 {
        font-size: 2em;
    }

    .qr-container {
        padding: 20px;
    }
}

.error {
    background: #4a1a1a;
    border: 2px solid #8a3a3a;
    color: #ff6b6b;
    padding: 12px;
    border-radius: 6px;
    margin-bottom: 15px;
}

.success {
    background: #1a4a1a;
    border: 2px solid #3a8a3a;
    color: #6bff6b;
    padding: 12px;
    border-radius: 6px;
    margin-bottom: 15px;
    text-align: center;
}