#main-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height:60px;
    background-color: #111111;
    display: flex;
    justify-content: center;
    align-items: center;
    border-bottom: 2px solid #ffa500;
    z-index: 1000;
    box-shadow: 0 4px 400px 0px rgba(255, 165, 0, 0.3)
}

body {
    background-color: #0f0f0f;
    color: #ffffff;
    font-family: system-ui, -apple-system, sans-serif;
    min-height: 100vh;
    margin: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding-top: 60px;
}

.lang-container {
    position: absolute;
    right: 20px;
    display: flex;
    gap: 5px;
    align-items: center;
}

.lang-btn {
    background: none;
    border: none;
    color: #aaaaaa;
    font-size: 12px;
    font-weight: bold;
    cursor: pointer;
    padding: 0;
}

.active-lang {
    color: #ffa131;
}

.active-btn:hover {
    color: #ffa13a;
}

.login-box {
    width: 100%;
    max-width: 400px;
    margin-top: 100px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 15px; 
    box-sizing: border-box;
    text-align: center;
    font-family: inherit;
}

.login-box h2 {
    margin-top: 0px;
    margin-bottom: 25px;
    text-align: center;
    font-size: 28px;
    font-weight: 800;
    font-family: inherit;
    letter-spacing: 1px;
    color: #ffffff;
    text-shadow: 0 0 3px rgba(242, 240, 235, 1);
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
    border: 0;
}


.user-group {
    width: 100%;
    height: 50px;
    padding: 15px;
    background-color: #ffa31a;
    color: #000000;
    border: none;
    border-radius: 5px;
    font-family: inherit;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 0 20px 1px #0f0f0f;
}

.user-group:hover {
    color: #ffa31a;
    background-color: #1a1a1a;
    border: 1px solid #ffa31a;
}

.user-group:active {
    transform: scale(0.95);
}

#search-bar, .input-field {
    padding: 12px;
    width: 100%;
    margin-bottom: 20px;
    font-size: 16px;
    font-family: inherit;
    background-color: #2b2b2b;
    color: white;
    border: 2px solid #333333;
    box-sizing: border-box;
}

#search-bar:focus, .input-field:focus {
    outline: none;
    border-color: #ffa31a;
}

.input-field:focus::placeholder {
    color: transparent;
}

.list-container {
    background: #181818;
    width: 100%;
    max-width: 400px;
    border-radius: 5px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    box-sizing: border-box;
    text-align: center;
    font-family: inherit;
    max-height: 60vh;
    overflow-y:auto;
}

.list-container::-webkit-scrollbar-thumb {
    background: #333333;
    background-color: rgba(255,163,26,0.3);
    border-radius: 10px;
    background-clip: padding-box;
}

.list-container::-webkit-scrollbar-thumb:hover {
    background: rgba(255,163,26,0.5);
}

::-webkit-scrollbar {
    width: 8px;
    padding: 5px;
    background: #1a1a1a;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: #333333;
    border-radius: 5px;
    border: none;
    background-clip: padding-box;
}

::-webkit-scrollbar-thumb:hover {
    background: #5b5a5a;
}

.machine-btn {
    width: 100%;
    padding: 15px;
    background-color: #ffa31a;
    color: #000000;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    font-weight: bold;
    font-family: inherit;
    cursor: pointer;
}

.machine-btn:hover {
    background-color: #cc8214;
}

.machine-btn:active {
    transform: scale(0.95);
}

.tab-container {
    width: 100%;
    max-width: 400px;
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 15px;
}

.tab-btn {
    flex: 1;
    padding: 12px;
    background-color: #2b2b2b;
    color:white;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: bold;
    font-family: inherit;
    cursor: pointer;
}

.active-tab {
    background-color: #ffa31a;
    color: #000000;
}

.tab-btn:hover {
    background-color: #cc8214;
}

.tab-btn:active {
    transform: scale(0.95);
}

.hidden {
    display: none !important;
}

.report-sort {
    max-width: 110px;
}

.report-sort label {
    display: block;
    margin-bottom: 8px;
}

#overview-screen {
    width: 100%;
    max-width: 1600px;
    padding: 24px 32px; 
    box-sizing: border-box;
}

#overview-screen h2 {
    margin: 0 0 24px;
    font-size: clamp(28px, 4vw, 40px);
    text-shadow: 4px 4px 10px rgba(255, 165, 0, 0.3);
}

.overview-columns {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
    width: 100%;
    align-items: start;
}

.column {
    min-width: 0;
    display: flex;
    flex-direction: column;
}

#dashboard-screen {
    width: 100%;
    max-width: 400px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

#dashboard-screen h2 {
    width: 100%;
    max-width: 400px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-shadow: 0 0 3px rgba(242, 240, 235, 1);
}

ul {
    list-style-type: none;
    padding: 0;
    margin: 0;
    width: 100%;
}

.fault-item {
    background-color: #2b2b2b;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 10px;
    display: flex;
    flex-direction: column;
    text-align: left;
    font-family: inherit;
    border-left: 5px solid #e63946;
    box-shadow: 0 0 5px 1px rgba(255, 0, 0, 0.5);
}

.fault-summary {
    padding: 8px 0;
    cursor: pointer;
    font-weight: 600;
    overflow-wrap: anywhere;
}

.fault-summary:focus-visible {
    outline: 2px solid #ffa31a;
    outline-offset: 4px;
}

.fault-description {
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.fault-card .timestamp {
    display: block;
}

.timestamp {
    font-size: 12px;
    color: #aaaaaa;
    margin-top: 8px;
}

#active-faults-list {
    width: 400px;
    list-style-type: none;
    padding: 10px;
}

.fault-item {
    background-color: #2b2b2b;
    padding: 10px;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    text-align: left;
    font-family: inherit;
    border-left: 5px solid #e63946;
}

.timestamp {
    font-size: 12px;
    color: #aaaaaa;
    margin-top: 8px;
    text-align: right;
}

.description-card {
    width: fit-content;
    background-color: #222222;
    padding: 10px;
    margin-top: 8px;
    border-radius: 6px;
    font-size: 14px;
    font-family: inherit;
    border-left: 3px solid #e63946;
    box-shadow: 0 4px 8px rgba(0,0,0,0.5);
}

.category-text {
    margin-top: 4px;
    font-family:inherit;
}

#header-logo {
    height: 40px;
    width: auto;
}

.modal-overlay {
    position:fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.8);
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
}

.modal-box {
    background-color: #1a1a1a;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    width: 80%;
    max-width: 350px;
    border: 1px solid #333333;
    box-shadow: 0 0 15px 4px rgba(255, 165, 0, 0.3);
}

.menu-toggle {
    position: absolute;
    left: 20px;
    width: 44px;
    height: 44px;
    padding: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    background-color: #0f0f0f;
    color: #ffa131;
    border: none;
    cursor: pointer;
}

.menu-toggle span {
    display: block; 
    width: 20px;
    height: 3px;
    background-color: currentColor;
    border-radius: 20px;
}


.menu-toggle:hover {
    background-color: #0f0f0f;
    color: #cc8214;
}

.menu-toggle:active {
    transform: scale(0.95);
}

.menu-toggle:focus-visible {
    outline: 2px solid #ffa31a;
    outline-offset: 3px;
}

#mobile-menu {
    position: fixed;
    top: 60px;
    left: 30px;
    width: 175px;
    background: none;
    border-radius: 20px;
    z-index: 1500;
    display: flex;
    flex-direction: column;
    gap: 3px;
    height: fit-content;
    padding-bottom: 10px;
}

.menu-item {
    width: 100%;
    padding: 15px;
    background-color: #ffa31a;
    color: #000000;
    border: 1px solid #0f0f0f;
    border-color: #0f0f0f;
    border-radius: 5px;
    font-family: inherit;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0,0,0,0.8)
}

.menu-item:hover {
    color: #ffa31a;
    background-color: #1a1a1a;
    border: 1px solid #ffa31a;
}

.menu-item:active {
    transform: scale(0.95);
}

dialog.modal-box {
    border: solid 1px #ffa131;
    color: white;
    margin: auto;
    box-sizing: border-box;
}

dialog.modal-box::backdrop {
    background-color: rgba(0,0,0, 0.8);
}

#logout-dialog button {
    margin-top: 8px;
}

#cancel-logout-btn {
    background-color: #333333;
    color: white;
}

.split-list {
    max-width: 100%;
    width: 100%;
    background: transparent;
    padding: 12px 10px;
    border: 1px solid #444444;
}

@media (max-width: 600px) {
    #overview-screen {
        padding: 20px 16px;
    }


    .overview-columns {
        grid-template-columns: 1fr;
}
}

#main-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-image: linear(to top, #ffa131, #0f0f0f);
    color: #6c6c6c;
    text-align: center;
    font-size: 8px;
    z-index: 1000;
    text-shadow: 0 1px 2px rgba(255, 165, 0, 0.3);
}

#main-footer p {
    margin: 12px 0;
}

body {
    padding-bottom: 50px;
    box-sizing: border-box;
}

#home-screen {
    width: 100%;
    max-width: 1200px;
    padding:25px; 
    box-sizing: border-box;
}

#home-screen > h1 {
    margin: 0 0 8px; 
    font-size: clamp(28px, 4vw, 40px);
    line-height: 1.2;
    text-shadow: 4px 4px 10px rgba(255, 165, 0, 0.3);
}

#home-screen > p {
    margin: 0 0 24px;
    font-size: 16px;
    line-height: 1.5;
    color: #aaaaaa;
}

.home-actions {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.home-actions button {
    width: 100%;
    height: auto;
    min-height: 64px;
    box-sizing: border-box;
}

@media (max-width: 600px) {
    .home-actions {
        grid-template-columns: 1fr;
    }
}