body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #0a0e17;
    color: #e0e0e0;
    line-height: 1.6;
    margin: 0;
    padding: 0;
}

header {
    background: linear-gradient(135deg, #0d1b3e, #152642);
    color: white;
    text-align: center;
    padding: 1.5rem 0;
    position: relative;
    border-bottom: 1px solid #1e2b48;
}

header h1 {
    margin: 0;
    font-size: 2rem;
    color: #4a7eff;
}

.back-btn {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #a0bcf8;
    text-decoration: none;
    font-weight: bold;
    padding: 0.5rem 1rem;
    border-radius: 5px;
    transition: background-color 0.3s;
    border: 1px solid #2a3e6d;
}

.back-btn:hover {
    background-color: rgba(74, 126, 255, 0.2);
    color: #ffffff;
}

.generator-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.input-section {
    background: #121826;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    border: 1px solid #1c2a45;
}

.input-group {
    margin-bottom: 1.5rem;
}

.input-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #a0bcf8;
}

.input-group textarea {
    width: 100%;
    padding: 0.8rem;
    background-color: #0d1424;
    border: 1px solid #253662;
    border-radius: 5px;
    font-size: 1rem;
    min-height: 100px;
    resize: vertical;
    color: #ffffff;
}

.input-group input[type="range"] {
    width: calc(100% - 50px);
    vertical-align: middle;
    background: #0d1424;
    border-radius: 5px;
}

#size-value {
    display: inline-block;
    width: 50px;
    text-align: right;
    margin-left: 10px;
    color: #a0bcf8;
}

.input-group input[type="color"] {
    width: 100%;
    height: 40px;
    padding: 2px;
    background: #0d1424;
    border: 1px solid #253662;
    border-radius: 5px;
    cursor: pointer;
}

.input-group select {
    width: 100%;
    padding: 0.8rem;
    background-color: #0d1424;
    border: 1px solid #253662;
    border-radius: 5px;
    font-size: 1rem;
    color: #ffffff;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%234a7eff' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.8rem center;
    background-size: 12px;
}

.input-group select option {
    background-color: #121826;
    color: #ffffff;
    padding: 0.5rem;
}

.options-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

button {
    background: linear-gradient(135deg, #0d1b3e, #152642);
    color: #a0bcf8;
    border: 1px solid #253662;
    padding: 1rem 1.5rem;
    border-radius: 5px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    width: 100%;
    transition: all 0.3s;
    margin-bottom: 1rem;
}

button:hover {
    background: linear-gradient(135deg, #152642, #1e3259);
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.3);
}

button:disabled {
    background: #1a233a;
    color: #4a5568;
    border-color: #2d3748;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.output-section {
    background: #121826;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    border: 1px solid #1c2a45;
}

.qr-code-container {
    display: flex;
    justify-content: center;
    margin-bottom: 2rem;
}

.qr-preview {
    text-align: center;
}

.qr-placeholder {
    background: #0d1424;
    border: 2px dashed #253662;
    border-radius: 10px;
    padding: 2rem;
    margin-top: 1rem;
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.qr-placeholder p {
    color: #a0bcf8;
    font-style: italic;
}

canvas {
    max-width: 100%;
    height: auto;
    border: 1px solid #253662;
    border-radius: 5px;
    background: white;
}

/* How to Use Section */
.how-to-use {
    background: #121826;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    margin: 2rem auto;
    grid-column: 1 / -1;
    border: 1px solid #1c2a45;
}

.how-to-use h2 {
    color: #4a7eff;
    margin-top: 0;
}

.steps-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.step {
    background: #0d1424;
    padding: 1.2rem;
    border-radius: 8px;
    position: relative;
    border: 1px solid #1c2a45;
}

.step-number {
    display: inline-block;
    width: 26px;
    height: 26px;
    background: linear-gradient(135deg, #0d1b3e, #152642);
    color: #4a7eff;
    border-radius: 50%;
    text-align: center;
    line-height: 26px;
    font-weight: bold;
    margin-right: 8px;
    border: 1px solid #253662;
}

.step p {
    color: #a0bcf8;
    margin: 0.5rem 0 0;
}

.toggle-details {
    background: transparent;
    color: #4a7eff;
    border: 2px solid #253662;
    margin: 0 auto;
    display: block;
    width: auto;
    padding: 0.8rem 1.5rem;
    transition: all 0.3s;
}

.toggle-details:hover {
    background: rgba(74, 126, 255, 0.1);
    transform: none;
    box-shadow: none;
}

.detailed-instructions {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s ease;
    margin-top: 1rem;
}

.detailed-instructions.show {
    max-height: 500px;
}

.detailed-instructions h3 {
    color: #4a7eff;
    margin-bottom: 0.5rem;
}

.detailed-instructions ul {
    padding-left: 1.2rem;
}

.detailed-instructions li {
    margin-bottom: 0.5rem;
    color: #a0bcf8;
}

.detailed-instructions strong {
    color: #4a7eff;
}

@media (max-width: 768px) {
    .generator-container {
        grid-template-columns: 1fr;
    }
    
    .options-section {
        grid-template-columns: 1fr;
    }
    
    header h1 {
        font-size: 1.5rem;
    }
}