/* Reset */
body {
    margin: 0;
    font-family: Arial;
    background: #dcdcdc;
    padding-top: 75px;
    padding-bottom: 65px;
}

/* Header */
header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    padding: 15px 25px;
    background: linear-gradient(to right, #2f80ed, #56ccf2);
    color: rgb(255, 255, 255);
    text-shadow: 1px 1px black;
}

header h1 {
    margin: 0;
    font-size: 28px;
    color: white;
    text-shadow: 2px 2px 0 black;
}

.date {
    color: white;
    font-weight: bold;
    text-shadow: 1px 1px 0 black;
}

/* Line */
hr {
    border: 1px solid #555;
}

/* Main Center */
main {
    height: 75vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Login box */
.login-box {
    display: flex;
    flex-direction: column;
    gap: 25px;
    align-items: center;
}

.login-box input {
    width: 220px;
    padding: 15px;
    border-radius: 30px;
    border: 1px solid black;
    background-color: #cfcfcf;
    text-align: center;
    font-size: 16px;
}

.login-box button {
    margin-top: 10px;
    padding: 12px 30px;
    border-radius: 25px;
    border: none;
    background: linear-gradient(to right, #2f80ed, #2d9cdb);
    color: white;
    font-size: 16px;
    cursor: pointer;
}

/* Footer */
footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background-color: #42a5f5;
    color: #ffffff;
    text-align: center;
    padding: 10px;
    font-weight: bold;
}


/***********************for dashboard***********************/

body {
    margin: 0;
    font-family: Arial;
    background: #dcdcdc;
}

/* Header */
header {
    display: flex;
    justify-content: space-between;
    padding: 15px 25px;
    background: linear-gradient(to right, #2f80ed, #56ccf2);
    color: rgb(255, 255, 255);
    text-shadow: 1px 1px black;
}

/* Stats */
.stats {
    display: flex;
    justify-content: space-around;
    padding: 20px;
}

.box {
    display: inline-block;
    width: 80px;
    height: 30px;
    background: #bbb;
    margin-left: 10px;
}

/* Card */
.card {
    background: #cfd8dc;
    margin: 20px;
    padding: 15px;
    border-radius: 15px;
    border: 1px solid #888;
}

.card h3 {
    margin-top: 0;
}

/* Calendar */
.calendar-card {
    width: 1000px;
    background: #fff;
    padding: 25px;
    border-radius: 15px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.day-names, .dates {
    display: grid;
    grid-template-columns: repeat(7, 1fr); /* 7 equal columns */
    text-align: center;
}

.day-names span {
    font-weight: bold;
    font-size: 0.8rem;
    padding-bottom: 5px;
}

.d {
    padding: 8px 0;
    font-size: 0.9rem;
    cursor: pointer;
}

/* Your custom colors */
.red { color: white; background-color: #ff4d4d; border-radius: 4px; }
.yellow { color: black; background-color: #ffeb3b; border-radius: 4px; }
.today { border: 1px solid #2196f3; border-radius: 4px; }

/* Table */
table {
    width: 100%;
    border-collapse: collapse;
}

th, td {
    padding: 8px;
    text-align: center;
}

button {
    padding: 5px 10px;
    background: #2f80ed;
    color: white;
    border: none;
    border-radius: 5px;
}

/* Footer */
footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background-color: #42a5f5;
    color: #ffffff;
    text-align: center;
    padding: 10px;
    font-weight: bold;
}



/**********************for worker***********************/
body {
    margin: 0;
    font-family: Arial;
    background: #dcdcdc;
}

/* Header */
header {
    display: flex;
    justify-content: space-between;
    padding: 15px 25px;
    background: linear-gradient(to right, #2f80ed, #56ccf2);
    color: rgb(255, 255, 255);
    text-shadow: 1px 1px black;
}

footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background-color: #42a5f5;
    color: #ffffff;
    text-align: center;
    padding: 10px;
    font-weight: bold;
}

.header-content { max-width: 1200px; margin: 0 auto; }
.top-row, .bottom-row { display: flex; justify-content: space-between; align-items: center; }

.brand { font-size: 1.5rem; margin: 0; text-shadow: 1px 1px 2px #000; }
.title { font-size: 1.1rem; margin: 0; color: #000; }

.name-id {
    background: white;
    color: #111;
    padding: 2px 15px;
    border-radius: 12px;
    font-size: 0.9rem;
    border: 1px solid #111;
    margin-top: 5px;
}

.date { font-weight: bold; color: #000; font-size: 0.9rem; }

/* Main Layout Alignment */
.main-content {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.tracker-layout {
    display: flex;
    align-items: flex-start;
    gap: 40px;
}

/* Left Section */
.input-section .row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
    font-weight: bold;
}

.input-section span { width: 130px; font-size: 0.9rem; }

.plus, .minus {
    width: 24px;
    height: 24px;
    border: none;
    border-radius: 4px;
    color: white;
    background-color: #1e88e5;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    line-height: 1;
}

.field {
    width: 50px;
    height: 26px;
    background: #e0e0e0;
    border-radius: 10px;
    margin: 0 10px;
    border: 1px solid #bbb;
    box-sizing: border-box;
    -moz-appearance: textfield;
}
.field::-webkit-outer-spin-button,
.field::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Middle Section */
.calendar-box {
    background: white;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    font-size: 0.875rem;
}

.cal-nav { display: flex; justify-content: space-around; margin-bottom: 10px; }
.cal-grid .nums { display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; text-align: center; }

/* Right Section Table */
.table-section {
    border: 1px solid #000;
    background: white;
    padding: 10px;
}

.data-table { border-collapse: collapse; width: 280px; }
.data-table th, .data-table td { padding: 10px 5px; font-size: 0.85rem; font-weight: bold; text-align: left; }
.data-table th:last-child, .data-table td:last-child { text-align: center; }

.pill {
    background: #e3f2fd;
    padding: 3px 12px;
    border-radius: 10px;
    font-size: 0.75rem;
}

/* Field counter display */
.field {
    text-align: center;
    font-size: 0.9rem;
    font-weight: bold;
    padding: 0;
}

/* Submit button (worker page) */
.submit-btn {
    padding: 12px 50px;
    font-size: 1rem;
    background: linear-gradient(to right, #2f80ed, #2d9cdb);
    color: white;
    border: none;
    border-radius: 25px;
    cursor: pointer;
}

.submit-btn:disabled {
    cursor: default;
}

/* Logout button (header) */
.logout-btn {
    background: rgba(255,255,255,0.25);
    border: 1px solid #111;
    color: #111;
    padding: 5px 14px;
    border-radius: 12px;
    cursor: pointer;
    font-size: 0.85rem;
}

/* Salary rates row (dashboard) */
.rates-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: flex-end;
    background: #e8f0fe;
    padding: 10px 15px;
    border-radius: 8px;
    margin-bottom: 15px;
}

.rates-row label {
    display: flex;
    flex-direction: column;
    font-size: 0.75rem;
    font-weight: bold;
    gap: 3px;
}

.rates-row input {
    width: 70px;
    padding: 5px;
    border: 1px solid #bbb;
    border-radius: 4px;
    text-align: center;
    font-size: 0.85rem;
}

.rates-row button {
    padding: 7px 16px;
    align-self: flex-end;
}