html, body {
    padding: 0;
    margin: 0;
    font-family: 'JetBrains Mono', monospace;
    height: 100%;
    width: 100%;
}

* {
    box-sizing: border-box;
}

#app {
    width: 100vw;
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

#controls {
    flex: 0 0 auto;
    position: relative;
    z-index: 10;
    width: 100%;
    height: 2em;
    color: var(--primary, #c9d1d9);
    background: var(--secondary, #010409);
    display: flex;
    user-select: none;
    overflow-x: auto;
    white-space: nowrap;
}

.section {
    display: flex;
    align-items: center;
}

.left-section {
    flex: 1;
}

.center-section {
    flex: 0 0 auto;
    justify-content: center;
}

.right-section {
    flex: 1;
    justify-content: flex-end;
}

#expiry-countdown {
    font-size: 0.85em;
    padding: 0 0.6em;
    opacity: 0.7;
}

@media (max-width: 850px) {
    .optional {
        display: none !important;
    }
}

.btn {
    background: transparent;
    border: none;
    color: var(--primary, #c9d1d9);
    font-family: 'JetBrains Mono', monospace;
    font-size: 1em;
    padding: 0 0.4em;
    cursor: pointer;
    white-space: nowrap;
    line-height: 2em;
    height: 2em;
}

.btn:hover {
    color: var(--highlight-color, #ffffff);
    background: var(--highlight, #161b22);
}

.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-menu {
    display: none;
    position: fixed;
    top: 2em;
    background: var(--secondary, #010409);
    border: 1px solid var(--highlight, #161b22);
    z-index: 1000;
    min-width: 140px;
    max-height: 400px;
    overflow-y: auto;
}

.dropdown-menu.open {
    display: block;
}

.dropdown-menu .dropdown-group-label {
    color: var(--primary, #c9d1d9);
    opacity: 0.5;
    font-size: 0.85em;
    padding: 0.3em 0.5em 0.1em;
    cursor: default;
}

.dropdown-menu .dropdown-item {
    display: block;
    width: 100%;
    background: transparent;
    border: none;
    color: var(--primary, #c9d1d9);
    font-family: 'JetBrains Mono', monospace;
    font-size: 1em;
    padding: 0.2em 0.8em;
    cursor: pointer;
    text-align: left;
    white-space: nowrap;
}

.dropdown-item:hover,
.dropdown-item.active {
    background: var(--highlight, #161b22);
}

#size-notice {
    position: fixed;
    top: 2em;
    left: 0;
    right: 0;
    z-index: 9999;
    padding: 10px 1em;
    font-size: 1.05em;
    justify-content: center;
    align-items: center;
    background: #5a1a1a;
    color: #f28b82;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

#version-label {
    padding: 0 0.6em;
    font-size: 0.8em;
    line-height: 2em;
    color: var(--primary, #c9d1d9);
    opacity: 0.4;
    pointer-events: none;
    user-select: none;
}

#editor-container {
    flex: 1;
    overflow: hidden;
    position: relative;
}

#editor-container .line-numbers {
    cursor: pointer !important;
}

#editor-container .highlighted-line + div {
    color: var(--highlighted-color, #f0f6fc) !important;
    background-color: var(--highlighted-bg, #161b22) !important;
    font-weight: bold !important;
}

#editor-container .placeholder-text::after {
    content: 'Paste (or type) some code...';
}

#editor-container .placeholder-text {
    position: absolute;
    opacity: 0.5;
    font-weight: lighter;
}
