/* General Styles */
body {
    margin: 0;
    font-family: 'Arial', sans-serif;
    color: #fff;
    background-color: #121212;
    justify-content: center;
    align-items: center;
    max-width: 100%;
    width: 99.9%;
    /*overflow: hidden;*/
}

h1, h2 {
    margin: 0 0 20px;
}

button {
    background: linear-gradient(90deg, #ff7e5f, #feb47b);
    border: none;
    padding: 10px 20px;
    color: white;
    font-size: 16px;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.3s;
}

button:hover {
    background: linear-gradient(90deg, #feb47b, #ff7e5f);
}

/* Login Section */
#login-section {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
}

.form-container {
    background: #1f1f1f;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.5);
    text-align: center;
    width: 300px;
}

input[type="text"], input[type="password"] {
    width: 100%;
    padding: 10px;
    margin-bottom: 15px;
    border: none;
    border-radius: 5px;
}

/* Dashboard Section */
.hidden {
    display: none;
}

header {
    display: flex;
    justify-content: space-between;
    padding: 1% 0%;
    background: #333;
    position: fixed;
    top: 0;
    width: 100%;
    box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.5);
    img{
        margin: auto 4%;
       height: 11vh;
        width: 17%;
    }
    button{
        margin-right: 5%;
        height: 7vh;
        width: auto;
    }
}

.stock-container {
    margin: 15vh 5%;
    padding: 20px;
    width: 100%;
}

.gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin: 4vh auto;
}

.card {
    background: #1f1f1f;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.5);
    width: 200px;
    text-align: center;
    transition: transform 0.3s;
}

.card:hover {
    transform: translateY(-10px);
}

#machine-details {
    margin: 15vh 5%;
    padding: 20px;
    width: 100%;
}

.tablinks {
    padding: 10px 20px;
    background: #333;
    color: white;
    border: none;
    cursor: pointer;
}

.tablinks.active {
    background: linear-gradient(90deg, #ff7e5f, #feb47b);
    border: none;
    padding: 10px 20px;
    color: white;
    font-size: 16px;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.3s;
}

.tabcontent {
    display: none;
    padding: 20px;
    background: white;
    border: 1px solid #ddd;
    margin: 20px;
    font-size: 100%;
}
#back-btn {
    margin-top: 20px;
}
/* Eye Icon */
.eye-icon {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: black;
}

.input-container {
    position: relative;
    margin-bottom: 15px;
}

.error-message {
    color: #ff4d4d;
    font-size: 14px;
    margin-top: 10px;
    text-align: center;
    display: none;
}
.editable{
    color: #020202;
    background-color: white;
}
table{
    text-align: center;
}
.filters{
    border: 3px solid white;
    margin-bottom: 10px;
    border-radius: 10px;
    padding: 3%;
    margin: 5% auto;
}
.buttons{
     display: flex; 
     justify-content: space-between; 
     align-items: center; 
}
.summary{  
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
}
.date{
    display: grid;
}
#add-stock-popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #1e1e1e;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.2);
}

#add-stock-popup input,
#add-stock-popup select,
#add-stock-popup textarea {
    width: 100%;
    padding: 10px;
    margin: 8px 0;
    border-radius: 5px;
    background: #333;
    color: white;
}

#add-stock-popup button {
    width: 100%;
    padding: 10px;
    margin-top: 10px;
    background: #28a745;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

#add-stock-popup button:hover {
    background: #218838;
}

.hidden {
    display: none;
}
.filter {
    width: 90%;
    display: flex;
    gap: 1%;
    align-items: center;
    justify-content: space-between;
    padding: 2%;
    border: 3px solid white;
    border-radius: 8px;
    box-shadow: 0px 2px 5px rgba(0, 0, 0, 0.1);
    margin-bottom: 15px;
}

.filter div {
    display: flex;
    flex-direction: column;
}

.filter label {
    font-weight: bold;
    margin-bottom: 5px;
}

.filter input,
.filter select {
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 14px;
    width: 90%;
}

.filter select {
    cursor: pointer;
}


@media (max-width: 480px) {
    .card {
      flex: 1 1 100%; /* One card per row */
    }
    .header,
    .footer {
      font-size: 16px;
      padding: 15px 0;
    }
    .buttons{
        display: block; 
   }
   .filter {
        width: 100%;
        display: inline;
        text-align: center;
        font-size: 75%;
    }
    table{
        font-size: 75%;
        button{
            font-size: 70%;
            padding: 5%;
        }
    }
  }