.content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.maze-controls {
    display: flex;
    justify-content: space-between;
    width: 500px;
    margin-top: 15px;
    margin-bottom: 5px;
}

.maze-controls-left {
    display: flex;
    align-items: center;
    gap: 5px;
}

.maze-controls-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.control-btn {
    background: #000;
    border: 1px solid #444;
    padding: 5px 12px;
    color: #C8A55E;
    cursor: pointer;
    font-family: monospace;
    font-size: 1.125em;
    text-transform: capitalize;
    transition: background-color 0.3s, color 0.3s, border-color 0.3s;
}

.control-btn:hover {
    background: #111;
    font-weight: bold;
    color: #FFD700;
    border-color: #FFD700;
}

.control-btn.reset-complete {
    box-shadow: 0 0 8px rgba(255, 0, 0, 0.3);
}

.control-btn.reset-complete:hover {
    box-shadow: 0 0 12px rgba(255, 0, 0, 0.5);
}

.info-btn {
    background: #000;
    border: none;
    padding: 0;
    color: #C8A55E;
    cursor: pointer;
    font-family: monospace;
    font-size: 1.125em;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s, color 0.3s;
    width: 30px;
    height: 30px;
}

.info-btn:hover {
    background: #111;
    color: #FFD700;
}

.info-btn svg {
    width: 22px;
    height: 22px;
    display: block;
}

.level-text {
    color: #C8A55E;
    font-family: monospace;
    font-size: 1.125em;
    text-transform: capitalize;
}

.maze-container {
    width: 500px;
    height: 500px;
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    grid-template-rows: repeat(6, 1fr);
    gap: 1px;
    background-color: #333;
    border: 2px solid #C8A55E;
    padding: 1px;
    position: relative;
}

.maze-cell {
    aspect-ratio: 1 / 1;
    border: 1px solid #222;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.maze-cell.wall {
    background-color: #1a1a1a;
}

.maze-cell.open {
    background-color: #888;
}

.maze-cell.visited {
    background-color: rgba(200, 165, 94, 0.3);
}

.maze-cell.player {
    background-color: #FFD700;
}

.counter-overlay {
    position: absolute;
    color: #C8A55E;
    font-family: monospace;
    font-size: 16px;
    font-weight: bold;
    z-index: 100;
    white-space: nowrap;
    pointer-events: none;
}

.counter-level {
    top: 8px;
    left: 8px;
}

.counter-moves {
    top: 8px;
    right: 8px;
    text-align: right;
}

.counter-highscore {
    bottom: 8px;
    left: 8px;
}

/* Win overlay */
.win-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.win-box {
    background-color: #1a1a1a;
    border: 2px solid #C8A55E;
    padding: 30px 40px;
    text-align: center;
    width: 25%;
    min-width: 200px;
}

.win-score {
    color: #C8A55E;
    font-family: monospace;
    font-size: 1.5em;
    font-weight: bold;
    margin-bottom: 5px;
    position: relative;
    text-align: center;
}

.win-moves {
    color: #C8A55E;
    font-family: monospace;
    font-size: 1.5em;
    font-weight: bold;
    margin-bottom: 15px;
    text-align: center;
}

.win-high-score {
    color: #C8A55E;
    font-family: monospace;
    font-size: 1.08em;
    margin-top: 10px;
    text-align: center;
    position: relative;
    display: inline-block;
}

.new-high-score-badge {
    color: #FF0000;
    font-size: 0.7em;
    font-weight: bold;
    position: absolute;
    top: -3px;
    margin-left: 3px;
}

h2 {
    color: #C8A55E;
    margin-bottom: 1rem;
}

.maze-title-container {
    text-align: center;
}

.fullscreen-btn {
    display: inline-block;
    background: #000;
    border: 1px solid #444;
    padding: 4px 8px;
    margin: -15px 5px 0 5px;
    text-decoration: none;
    color: #C8A55E;
    cursor: pointer;
    font-family: monospace;
    font-size: 0.96em;
    transition: background-color 0.3s, color 0.3s;
}

.fullscreen-btn:hover {
    background: #111;
    font-weight: bold;
    color: #FFD700;
    border-color: #FFD700;
}

/* Full screen mode styles */
body.fullscreen-mode {
    margin: 0;
    padding: 0;
    overflow: hidden;
}

body.fullscreen-mode .wrapper {
    margin: 0;
    padding: 0;
    width: 100%;
}

body.fullscreen-mode .wrapper > .header {
    display: none;
}

body.fullscreen-mode .content {
    padding: 0;
    margin: 0;
    height: 100vh;
    justify-content: center;
    overflow: hidden;
    gap: 0;
}

body.fullscreen-mode .maze-title-container {
    width: 630px;
    height: 0;
    margin: 0;
    padding: 0;
    position: relative;
    overflow: visible;
}

body.fullscreen-mode h2 {
    margin: 0;
    display: none;
}

.exit-fullscreen-btn,
.home-btn {
    display: none;
    background: #000;
    border: 1px solid #444;
    padding: 5px 10px;
    margin: 0 5px;
    text-decoration: none;
    color: #C8A55E;
    cursor: pointer;
    font-family: monospace;
    transition: background-color 0.3s, color 0.3s;
}

.exit-fullscreen-btn:hover,
.home-btn:hover {
    background: #111;
    font-weight: bold;
    color: #FFD700;
    border-color: #FFD700;
}

body.fullscreen-mode #exitFullscreenBtn,
body.fullscreen-mode .home-btn {
    display: inline-block;
    position: fixed;
    top: 10px;
    z-index: 100;
}

body.fullscreen-mode .home-btn {
    left: 10px;
}

body.fullscreen-mode #exitFullscreenBtn {
    right: 10px;
}

body.fullscreen-mode.editor-mode #exitEditorBtnTop {
    display: inline-block;
    position: fixed;
    top: 10px;
    right: calc(10px + 147px);
    z-index: 100;
}

body.fullscreen-mode .fullscreen-btn {
    display: none;
}

body.fullscreen-mode .maze-container {
    width: 630px;
    height: 630px;
}

body.fullscreen-mode .maze-controls {
    width: 630px;
    margin-bottom: 5px;
}

/* Scale up all elements in fullscreen proportionally */
body.fullscreen-mode .control-btn {
    font-size: 1.35em;
    padding: 6px 14.4px;
}

body.fullscreen-mode .info-btn {
    width: 36px;
    height: 36px;
}

body.fullscreen-mode .info-btn svg {
    width: 26.4px;
    height: 26.4px;
}

body.fullscreen-mode .level-text {
    font-size: 1.35em;
}

body.fullscreen-mode .counter-overlay {
    font-size: 19.2px;
}

body.fullscreen-mode .win-box {
    width: 33.75%;
    padding: 40.5px 54px;
    min-width: 270px;
}

body.fullscreen-mode .win-score {
    font-size: 2.025em;
    margin-bottom: 6.75px;
}

body.fullscreen-mode .win-moves {
    font-size: 2.025em;
    margin-bottom: 20.25px;
}

body.fullscreen-mode .win-high-score {
    font-size: 1.458em;
    margin-top: 13.5px;
}

body.fullscreen-mode .new-high-score-badge {
    font-size: 0.7em;
    top: -4px;
    margin-left: 4px;
}

/* Inline Menu (non-fullscreen) */
.menu-inline {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #000;
    display: none;
    align-items: flex-start;
    justify-content: center;
    z-index: 10;
    padding-top: 10px;
    overflow-y: auto;
}

.menu-inline .menu-content {
    text-align: center;
    width: 100%;
}

/* Hide counter overlays when inline menu is open */
.menu-inline-open .counter-overlay {
    display: none;
}

/* Compact styling for inline menu only */
.menu-inline .menu-tab-btn {
    padding: 8px 16px;
    font-size: 1em;
}

.menu-inline .level-grid {
    gap: 10px;
    margin-bottom: 0;
    height: 100%;
    overflow-y: auto;
    align-content: flex-start;
}

/* Dark mode scrollbar for inline level grid */
.menu-inline .level-grid::-webkit-scrollbar {
    width: 12px;
}

.menu-inline .level-grid::-webkit-scrollbar-track {
    background: #000;
    border: 1px solid #444;
}

.menu-inline .level-grid::-webkit-scrollbar-thumb {
    background: #444;
    border: 1px solid #666;
}

.menu-inline .level-grid::-webkit-scrollbar-thumb:hover {
    background: #666;
}

.menu-inline .level-btn {
    padding: 10px;
    font-size: 1.1em;
}

.menu-inline .menu-close-btn {
    padding: 8px 16px;
    font-size: 1em;
    margin-top: 20px;
}

/* Menu overlay (fullscreen only) */
.menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
    display: none;
    align-items: flex-start;
    justify-content: center;
    z-index: 2000;
    padding-top: 5vh;
    overflow-y: auto;
}

body.fullscreen-mode .menu-overlay {
    padding-top: 75px;
}

body.fullscreen-mode #infoOverlay {
    padding-top: 75px;
}

.menu-overlay .menu-content {
    text-align: center;
    width: calc(75vh + 100px);
    max-width: 90vw;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.menu-overlay .menu-tabs {
    width: 100%;
}

.menu-overlay #menuContentOverlay {
    width: 100%;
}

.menu-overlay .menu-close-btn {
    align-self: center;
    margin-top: 20px;
}

/* Hide inline menu in fullscreen */
body.fullscreen-mode .menu-inline {
    display: none !important;
}

.menu-title {
    color: #C8A55E;
    font-family: monospace;
    font-size: 1.5em;
    margin-bottom: 20px;
    margin-top: 10px;
}

.menu-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    justify-content: center;
}

/* Fixed height for inline menu content area */
.menu-inline #menuContentInline {
    height: 360px;
    overflow: hidden;
}

.menu-tab-btn {
    background: #000;
    border: 2px solid #444;
    padding: 12px 24px;
    color: #C8A55E;
    cursor: pointer;
    font-family: monospace;
    font-size: 1.2em;
    transition: background-color 0.3s, color 0.3s, border-color 0.3s;
    flex: 1;
}

.menu-tab-btn:hover {
    background: #111;
    color: #FFD700;
    border-color: #FFD700;
}

.menu-tab-btn.active {
    background: #111;
    font-weight: bold;
    color: #FFD700;
    border-color: #FFD700;
}

.level-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
    margin-bottom: 20px;
}

.level-btn {
    background: #000;
    border: 2px solid #444;
    padding: 18px;
    color: #C8A55E;
    cursor: pointer;
    font-family: monospace;
    font-size: 1.35em;
    transition: background-color 0.3s, color 0.3s, border-color 0.3s;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
}

.level-btn-number {
    margin-top: 0px;
}

.level-btn-score {
    color: #FFFFFF;
    font-size: 0.7em;
    margin-top: 8px;
}

/* High Scores Tab - Split Layout */
.highscores-container {
    display: flex;
    gap: 20px;
    width: 100%;
    align-items: flex-start;
    height: 100%;
}

/* Match inline menu heights */
.menu-inline .highscores-container {
    height: 100%;
}

.level-select-table {
    display: flex;
    flex-direction: column;
    gap: 5px;
    max-height: 400px;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 10px;
}

/* Match height in inline menu */
.menu-inline .level-select-table {
    max-height: 100%;
    height: 100%;
}

/* Fullscreen level select table height */
body.fullscreen-mode .level-select-table {
    height: 495px;
    max-height: 495px;
}

/* Dark mode scrollbar */
.level-select-table::-webkit-scrollbar {
    width: 12px;
}

.level-select-table::-webkit-scrollbar-track {
    background: #000;
    border: 1px solid #444;
}

.level-select-table::-webkit-scrollbar-thumb {
    background: #444;
    border: 1px solid #666;
}

.level-select-table::-webkit-scrollbar-thumb:hover {
    background: #666;
}

.level-select-item {
    background: #000;
    border: 2px solid #444;
    padding: 8px;
    color: #C8A55E;
    cursor: pointer;
    font-family: monospace;
    font-size: 1em;
    text-align: center;
    min-width: 80px;
    transition: background-color 0.3s, color 0.3s, border-color 0.3s;
}

.level-select-item:hover {
    background: #111;
    font-weight: bold;
    color: #FFD700;
    border-color: #FFD700;
}

.level-select-item.active {
    background: #111;
    color: #FFD700;
    border-color: #FFD700;
}

.leaderboard-display {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 200px;
    background-color: #0a0a0a;
    padding: 20px;
    border-radius: 4px;
}

/* Match height in inline menu */
.menu-inline .leaderboard-display {
    height: 100%;
    min-height: auto;
    padding: 0 5px 5px 5px;
    justify-content: flex-start;
}

.leaderboard-title {
    color: #C8A55E;
    font-family: monospace;
    font-size: 1.625em;
    margin-bottom: 15px;
    text-align: center;
    margin-top: 0;
}

/* Inline menu leaderboard title positioning */
.menu-inline .leaderboard-title {
    margin-top: 10px;
    margin-bottom: 15px;
}

/* Fullscreen leaderboard title positioning */
body.fullscreen-mode .leaderboard-title {
    margin-top: 10px;
}

.leaderboard-table {
    border-collapse: collapse;
    font-family: monospace;
    color: #C8A55E;
    font-size: 1.2em;
    table-layout: auto;
    width: 100%;
}

.leaderboard-table col.col-ranking {
    width: 1%;
    white-space: nowrap;
}

.leaderboard-table col.col-moves {
    width: 1%;
    white-space: nowrap;
}

.leaderboard-table col.col-name {
    width: auto;
}

.leaderboard-table th {
    color: #FFD700;
    font-weight: bold;
    padding: 6px 16px;
    text-align: center;
    border-bottom: 2px solid #444;
}

.leaderboard-table td {
    padding: 4px 16px;
    text-align: center;
}

.leaderboard-table tr.current-user td {
    font-weight: bold;
    color: #FFD700;
}

.leaderboard-table tr.optimal-row td {
    color: #666;
    font-size: 0.75em;
    padding: 4px 16px;
    vertical-align: middle;
}

.leaderboard-table .optimal-reveal {
    cursor: pointer;
    user-select: none;
    font-size: 1em;
    display: inline-block;
    text-align: center;
}

.leaderboard-table .optimal-reveal:hover {
    color: #888;
}

.leaderboard-table .optimal-value {
    cursor: pointer;
    font-size: 1em;
    color: #C8A55E;
    display: inline-block;
    text-align: center;
}

/* Fullscreen scaling for High Scores */
body.fullscreen-mode .highscores-container {
    width: 100%;
}

body.fullscreen-mode .level-select-table {
    min-width: 150px;
}

body.fullscreen-mode .level-select-item {
    padding: 10px;
    font-size: 1.25em;
}

body.fullscreen-mode .leaderboard-title {
    font-size: 2.03em;
}

body.fullscreen-mode .leaderboard-table {
    font-size: 1.5em;
}

body.fullscreen-mode .leaderboard-table th {
    padding: 8px 16px;
}

body.fullscreen-mode .leaderboard-table td {
    padding: 5px 16px;
}

/* Fullscreen scaling for Level Select grid */
body.fullscreen-mode .level-btn {
    padding: 14px;
}

/* Fullscreen styling for Info content */
body.fullscreen-mode .info-content {
    max-height: 525px;
}

/* Match Menu overlay height in fullscreen - reduce by 30px */
body.fullscreen-mode .menu-overlay #menuContentOverlay {
    height: 495px;
    overflow: hidden;
}

body.fullscreen-mode .level-grid {
    height: 100%;
    overflow-y: auto;
    margin-bottom: 0;
    align-content: flex-start;
}

body.fullscreen-mode .highscores-container {
    height: 100%;
}

body.fullscreen-mode .leaderboard-display {
    height: 100%;
    min-height: auto;
    padding: 0 20px 20px 20px;
    justify-content: flex-start;
}

body.fullscreen-mode .info-header {
    padding: 15px 20px 12px 20px;
    border-bottom: 2px solid #FFF;
}

body.fullscreen-mode .info-header h2 {
    font-size: 2.16em;
}

/* Ensure menu overlay content doesn't overflow */
body.fullscreen-mode .menu-overlay .menu-content {
    max-height: 90vh;
    overflow: visible;
}

.level-btn:hover {
    background: #111;
    font-weight: bold;
    color: #FFD700;
    border-color: #FFD700;
}

.level-btn.locked {
    color: #444;
    background: #111;
    border-color: #333;
    cursor: not-allowed;
    pointer-events: none;
}

.level-btn.locked:hover {
    background: #111;
    color: #444;
    border-color: #333;
    font-weight: normal;
}

.menu-close-btn {
    background: #000;
    border: 1px solid #444;
    padding: 10px 20px;
    color: #C8A55E;
    cursor: pointer;
    font-family: monospace;
    font-size: 1.2em;
    transition: background-color 0.3s, color 0.3s, border-color 0.3s;
}

.menu-close-btn:hover {
    background: #111;
    font-weight: bold;
    color: #FFD700;
    border-color: #FFD700;
}

/* Info content styling */
.info-content {
    width: 100%;
    max-height: 375px;
    overflow-y: auto;
    padding: 0;
    text-align: left;
    position: relative;
    border: 2px solid #444;
    border-radius: 4px;
}

.info-header {
    position: sticky;
    top: 0;
    background: #000;
    padding: 12px 20px 10px 20px;
    border-bottom: 2px solid #FFF;
    z-index: 10;
}

.info-header h2 {
    color: #FFD700;
    font-family: monospace;
    font-size: 1.8em;
    font-weight: bold;
    margin: 0;
}

.info-scrollable {
    padding: 5px 20px 20px 20px;
}

/* Dark mode scrollbar for info content */
.info-content::-webkit-scrollbar {
    width: 12px;
}

.info-content::-webkit-scrollbar-track {
    background: #000;
    border: 1px solid #444;
}

.info-content::-webkit-scrollbar-thumb {
    background: #444;
    border: 1px solid #666;
}

.info-content::-webkit-scrollbar-thumb:hover {
    background: #666;
}

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

.info-section h3 {
    color: #f8dc8d;
    font-family: monospace;
    font-size: 1.5em;
    font-weight: bold;
    margin-bottom: 10px;
}

.info-subsection {
    color: #E8BE76;
    font-family: monospace;
    font-size: 1.2em;
    font-weight: bold;
    margin-top: 15px;
    margin-bottom: 8px;
}

.info-section p {
    color: #C8A55E;
    font-family: monospace;
    font-size: 1.1em;
    line-height: 1.6;
    margin: 0;
}

.info-inline-btn {
    background: #000;
    border: 1px solid #444;
    padding: 2px 8px;
    color: #C8A55E;
    cursor: pointer;
    font-family: monospace;
    font-size: 0.95em;
    transition: background-color 0.3s, color 0.3s, border-color 0.3s;
}

.info-inline-btn:hover {
    background: #111;
    font-weight: bold;
    color: #FFD700;
    border-color: #FFD700;
}

.key-display {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 10px 0;
}

.key-img {
    background: #1a1a1a;
    border: 2px solid #444;
    border-radius: 4px;
    padding: 4px 8px;
    color: #C8A55E;
    font-family: monospace;
    font-size: 0.9em;
    font-weight: bold;
    min-width: 30px;
    text-align: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.key-group {
    display: flex;
    gap: 5px;
    margin: 5px 0;
}

/* Editor mode styles */
body.editor-mode .maze-controls-left {
    justify-content: center;
}

body.editor-mode #prevLevelBtn,
body.editor-mode #nextLevelBtn,
body.editor-mode .level-text {
    display: none;
}

body.editor-mode #userLevelsBtn {
    display: inline-block;
}

#userLevelsBtn {
    display: none;
}

body.editor-mode #editorBtn {
    display: none;
}

#exitEditorBtnTop {
    display: none;
}

/* Editor mode - fixed board size */
body.editor-mode .maze-container {
    width: 580px;
    height: 580px;
}

/* Editor mode - hide level counter and high score */
body.editor-mode .counter-level,
body.editor-mode .counter-highscore {
    display: none;
}

/* Editor mode - show grid size in bottom right */
.counter-gridsize {
    display: none;
    position: absolute;
    bottom: 10px;
    right: 10px;
    background-color: rgba(0, 0, 0, 0.8);
    color: #C8A55E;
    padding: 8px 12px;
    font-family: monospace;
    font-size: 1.125em;
    border: 1px solid #444;
    border-radius: 4px;
    pointer-events: none;
    z-index: 10;
}

body.editor-mode .counter-gridsize {
    display: block;
}

/* Exit fullscreen confirmation dialog */
.exit-confirm-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 3000;
}

.exit-confirm-box {
    width: 400px;
    height: 200px;
    background-color: #000;
    border: 2px solid #666;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    gap: 20px;
}

/* Export dialog */
.export-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 3000;
}

.export-box {
    width: 700px;
    height: 600px;
    background-color: #000;
    border: 2px solid #666;
    display: flex;
    flex-direction: column;
    padding: 20px;
    gap: 15px;
    position: relative;
}

.export-header {
    display: flex;
    align-items: center;
    gap: 10px;
}

.export-text {
    color: #C8A55E;
    font-family: monospace;
    font-size: 1.43em;
}

.export-close-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 20.8px;
    height: 20.8px;
    background: #000;
    border: 2px solid #666;
    color: #C8A55E;
    font-family: monospace;
    font-size: 0.845em;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s, color 0.3s, border-color 0.3s;
}

.export-close-btn:hover {
    background: #111;
    color: #FFD700;
    border-color: #FFD700;
}

.export-textarea {
    flex: 1;
    background-color: #333;
    border: 1px solid #666;
    color: #C8A55E;
    font-family: monospace;
    font-size: 1.521em;
    padding: 10px;
    resize: none;
    margin: 0 10px 15px 10px;
    white-space: pre;
    overflow-x: auto;
    overflow-y: auto;
    word-wrap: normal;
    tab-size: 2;
}

.export-textarea:focus {
    outline: none;
    border-color: #FFD700;
}

.exit-confirm-text {
    color: #C8A55E;
    font-family: monospace;
    font-size: 1.1em;
    text-align: center;
    line-height: 1.5;
}

.exit-confirm-buttons {
    display: flex;
    gap: 15px;
}

.exit-confirm-btn {
    background: #000;
    border: 1px solid #444;
    padding: 8px 16px;
    color: #C8A55E;
    cursor: pointer;
    font-family: monospace;
    font-size: 1em;
    transition: background-color 0.3s, color 0.3s, border-color 0.3s;
}

.exit-confirm-btn:hover {
    background: #111;
    font-weight: bold;
    color: #FFD700;
    border-color: #FFD700;
}

/* Editor controls row 2 */
.editor-controls-row2 {
    display: none;
    justify-content: space-between;
    width: 580px;
    margin-top: 6px;
    margin-bottom: 8px;
}

.editor-controls-row2 .control-btn {
    padding: 4px 9.6px;
    font-size: 0.9em;
}

/* Board size buttons - same height as regular buttons */
.editor-controls-row2 .editor-controls-left .control-btn {
    padding: 4px 9.6px;
    font-size: 0.9em;
}

/* Save/Publish/Export/Import buttons 30% larger than before */
.editor-controls-row2 .editor-controls-right .control-btn {
    padding: 5.2px 12.48px;
    font-size: 0.936em;
}

.editor-controls-row2 .board-size-text {
    font-size: 1.0296em;
}

body.editor-mode .editor-controls-row2 {
    display: flex;
}

body.editor-mode .maze-controls {
    width: 580px;
}

.editor-controls-left {
    display: flex;
    align-items: center;
    gap: 5px;
}

.editor-controls-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.board-size-text {
    color: #C8A55E;
    font-family: monospace;
    font-size: 1.125em;
    text-transform: capitalize;
}

/* Mouse icon styles */
.mouse-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    vertical-align: middle;
}

.mouse-icon svg {
    width: 42px;
    height: 42px;
    display: block;
}

/* Login dialog */
.login-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 3000;
    pointer-events: none;
}

.login-overlay.active {
    pointer-events: auto;
}

.login-box {
    width: 400px;
    height: 260px;
    background-color: #000;
    border: 2px solid #666;
    display: flex;
    flex-direction: column;
    padding: 25px;
    position: relative;
    pointer-events: auto;
}

.login-close-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 25px;
    height: 25px;
    background: #000;
    border: 2px solid #666;
    color: #C8A55E;
    font-family: monospace;
    font-size: 0.9em;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s, color 0.3s, border-color 0.3s;
}

.login-close-btn:hover {
    background: #111;
    color: #FFD700;
    border-color: #FFD700;
}

.login-form {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    padding-top: 25px;
}

.login-fields {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.login-field {
    width: 100%;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    height: 20px;
}

.login-label {
    color: #C8A55E;
    font-family: monospace;
    font-size: 1em;
    white-space: nowrap;
    min-width: 75px;
}

.login-input {
    flex: 1;
    background-color: #1a1a1a;
    border: 1px solid #666;
    color: #C8A55E;
    font-family: monospace;
    font-size: 1em;
    padding: 6px;
    box-sizing: border-box;
}

.login-input:focus {
    outline: none;
    border-color: #FFD700;
}

.login-button-main {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}

.login-submit-btn {
    width: 150px;
    height: 28px;
    background: #000;
    border: 1px solid #444;
    padding: 0;
    color: #C8A55E;
    cursor: pointer;
    font-family: monospace;
    font-size: 1em;
    transition: background-color 0.3s, color 0.3s, border-color 0.3s, font-weight 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.login-submit-btn.signup-mode {
    font-weight: normal;
}

.login-submit-btn:hover {
    background: #111;
    color: #FFD700;
    border-color: #FFD700;
}

.login-buttons-bottom {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-top: 15px;
}

.login-secondary-btn {
    width: 150px;
    height: 28px;
    background: #000;
    border: 1px solid #444;
    padding: 0;
    color: #C8A55E;
    cursor: pointer;
    font-family: monospace;
    font-size: 1em;
    transition: background-color 0.3s, color 0.3s, border-color 0.3s, box-shadow 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-secondary-btn:hover {
    background: #111;
    color: #FFD700;
    border-color: #FFD700;
}

#loginOverlay.signup-mode #signUpBtn {
    border-color: #008000;
    color: #008000;
    box-shadow: 0 0 15px rgba(0, 128, 0, 0.6), inset 0 0 10px rgba(0, 128, 0, 0.2);
}

#loginOverlay.signup-mode #signUpBtn:hover {
    background: #001100;
    color: #199919;
    border-color: #199919;
    box-shadow: 0 0 20px rgba(0, 128, 0, 0.8), inset 0 0 15px rgba(0, 128, 0, 0.3);
}
