body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background-color: #1a1a1a;
    color: #f0f0f0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    min-height: 100vh;
    margin: 0;
    padding: 2rem 0;
}

.container {
    background-color: #2a2a2a;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
    width: 90%;
    max-width: 600px;
}

h1, h2, h3 {
    color: #e0e0e0;
    border-bottom: 1px solid #444;
    padding-bottom: 0.5rem;
    margin-bottom: 1rem;
}

h1 {
    margin-top: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.5rem;
    font-size: 1.8rem;
}

#logo {
    height: 1.5em;
    vertical-align: middle;
    cursor: pointer;
    transition: transform 0.2s;
}

#logo:hover {
    transform: scale(1.1);
}

#logo.spinning {
    animation: spin 1s linear;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.warning {
    background-color: #4d2828;
    color: #ffcccc;
    border: 1px solid #c83737;
    padding: 1rem;
    border-radius: 4px;
    margin-bottom: 1.5rem;
}

.section {
    margin-bottom: 1.5rem;
}

.option {
    margin-bottom: 1rem;
}

.option-description {
    font-size: 0.9rem;
    color: #aaa;
    margin-left: 24px;
    margin-top: 4px;
}

.option-description.warning-text {
    color: #ffcccc;
}

.option-description.small-desc {
    font-size: 0.8rem;
    margin-left: 0;
    margin-top: 2px;
}

input[type="file"], input[type="number"] {
    color: #ccc;
    width: 100%;
    background-color: #1e1e1e;
    border: 1px solid #444;
    padding: 8px;
    border-radius: 4px;
    box-sizing: border-box; /* Ensures padding doesn't affect width */
}

input[type="range"] {
    width: 70%;
    vertical-align: middle;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: bold;
}

.inline-label {
    display: inline-block;
    margin-bottom: 0;
    font-weight: bold;
}

button {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 0.8rem 1.5rem;
    font-size: 1rem;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s;
    width: 100%;
    margin-top: 1rem;
}

button:hover {
    background-color: #0056b3;
}

.secondary-btn {
    background-color: #4a4a4a;
    margin-top: 0.5rem;
}

.secondary-btn:hover {
    background-color: #5a5a5a;
}

#custom-options, #byte-options, #devil-options, #reverse-options {
    background-color: #333;
    padding: 1rem;
    border-radius: 4px;
    margin-top: 1rem;
}

#result-section {
    margin-top: 1.5rem;
    padding: 1rem;
    background-color: #3c3c3c;
    border-radius: 4px;
}

#result-section a {
    display: inline-block;
    margin-top: 0.5rem;
    color: #8ab4f8;
    text-decoration: none;
    font-weight: bold;
    padding: 0.5rem 1rem;
    background-color: #4a4a4a;
    border-radius: 4px;
}

#result-section a:hover {
    background-color: #5a5a5a;
    text-decoration: underline;
}

.error {
    color: #ffcccc;
    background-color: #4d2828;
    padding: 1rem;
    border: 1px solid #c83737;
    border-radius: 4px;
    margin-top: 1rem;
}

.hidden {
    display: none;
}

#spin-counter-container {
    position: fixed;
    top: 15px;
    left: 15px;
    background-color: #2a2a2a;
    color: #f0f0f0;
    padding: 10px 15px;
    border-radius: 6px;
    font-weight: bold;
    font-size: 0.9rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.5);
    border: 1px solid #444;
    z-index: 1000;
}

.youtube-link {
    position: fixed;
    top: 15px;
    right: 15px;
    background-color: #2a2a2a;
    color: #f0f0f0;
    padding: 10px 15px;
    border-radius: 6px;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: bold;
    font-size: 0.9rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.5);
    transition: background-color 0.2s, transform 0.2s;
    border: 1px solid #444;
    z-index: 1000;
}

.youtube-link:hover {
    background-color: #3a3a3a;
    transform: translateY(-2px);
    text-decoration: none;
}

.youtube-link img {
    height: 1.5em;
    width: auto;
}

@media (max-width: 680px) {
    .youtube-link span {
        display: none;
    }
    .youtube-link {
        padding: 8px;
    }
    #spin-counter-container {
        position: fixed;
        top: auto;
        bottom: 15px;
        left: 15px;
    }
    .container {
        margin-top: 50px;
    }
}

#about-section {
    margin-top: 1.5rem;
    padding: 0.5rem 1rem 1rem 1rem;
    background-color: #333;
    border-radius: 4px;
    border: 1px solid #444;
}

#about-section h2 {
    margin-top: 0.5rem;
    font-size: 1.2rem;
}

#about-section p {
    line-height: 1.6;
    color: #ccc;
    margin-bottom: 0;
}

footer {
    text-align: center;
    margin-top: 2rem;
    color: #888;
    font-size: 0.9rem;
}