html {
  font-size: 14px;
}

hr {
  border: 0;
  border-top: 1px solid #64758a;
}

textarea {
  resize: none;
}

button {
  border: none;
  border-radius: 6px;
  font-size: 1rem;
  font-weight: bold;
  cursor: pointer;
}

button:focus {
  outline: 2px solid #64758a;
}

button:hover {
  opacity: 0.9;
}

button:disabled {
  cursor: not-allowed;
}

button:disabled::after {
  cursor: pointer;
}

body {
  font-family: 'Segoe UI', 'Helvetica Neue', sans-serif;
  background-color: #2d3748;
  color: #e2e8f0;
  display: grid;
  grid-template-rows: auto 1fr;
  min-height: 100vh;
  padding: 0;
  margin: 0;
}

header {
  border-bottom: 1px solid #64758a;
  background-color: #2d3748;
  display: flex;
  justify-content: space-between;
  align-items: center;
  top: 0;
  position: sticky;
  z-index: 1000;
  min-width: 0;
  padding: 10px;
  margin: 0;
}

#user-panel {
  display: none; /* flex */
  align-items: center;
  justify-content: flex-end;
  flex: 1;
  min-width: 0;
  gap: 10px;
  padding-left: 10px;
}

#user-title {
  font-size: 1.1rem;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: right;
  min-width: 0;
  padding: 0;
  margin: 0;
}

.user-button {
  background-color: transparent;
  transition: background 0.3s;
  color: #fff;
  flex-shrink: 0;
  width: 80px;
  height: 40px;
  padding: 0;
  margin: 0;
}

.clock-in {
  background-color: #4caf50;
}

.clock-out {
  background-color: #f44336;
}

.container {
  display: flex;
}

.menu {
  display: none; /* block */
  border-right: 1px solid #64758a;
  background-color: #2d3748;
  flex: 0 0 auto;
  width: 226px;
  padding: 0;
  margin: 0;
}

.menu-item {
  display: flex;
  align-items: center;
  padding: 12px 30px;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
}

.menu-item.active {
  background-color: #4a5568;
}

.menu-item.active .ti {
  color: #fff;
}

.menu-item:hover {
  background-color: #718096;
}

.menu-item:hover .ti {
  color: #fff;
}

.menu-item .ti {
  font-size: 1.5rem;
  margin-right: 15px;
  color: #a0aec0;
  transition: color 0.3s ease;
  flex-shrink: 0;
}

.content {
  background-color: #1e2734;
  color: #cbd5e0;
  flex: 1;
  text-align: center;
  padding: 5px;
}

.content-wrapper {
  display: none; /* flex */
  justify-content: center;
  padding: 5px;
}

.content-box {
  border: 1px solid #64758a;
  border-radius: 6px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  background-color: #2d3748;
  width: 100%;
  max-width: 600px;
  padding: 1.5rem 2rem;
  margin-top: 5px;
}

.content-box h2 {
  font-size: 1.5rem;
  color: #fff;
  margin: 0 0 1rem 0;
}

.content-form {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}

.content-submit {
  background-color: #4caf50;
  transition: background 0.3s;
  color: #fff;
  width: 100%;
  padding: 0.75rem;
  margin-top: 0.5rem;
}

.content-button {
  background-color: #4a5568;
  transition: background 0.3s;
  color: #fff;
  width: 100%;
  padding: 0.75rem;
  margin-top: 0.5rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  text-align: left;
}

.form-2columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.2rem;
}

.form-2columnsA {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 1.2rem;
}

.form-2columnsB {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 1.2rem;
}

.form-3columns {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 1.2rem;
}

.form-group input, .form-group textarea, .form-group select {
  font-size: 1rem;
  border: 1px solid #64758a;
  border-radius: 4px;
  background-color: #1e2734;
  color: #fff;
  transition: all 0.3s;
  width: auto;
  min-width: 0;
  padding: 0.5rem;
}

.form-group input:focus, .form-group textarea:focus, .form-group select:focus {
  border-color: #718096;
  box-shadow: 0 0 0 2px rgba(113, 128, 150, 0.3);
  outline: none;
}

.view-table, .edit-table {
  border-collapse: collapse;
  width: 100%;
  margin-top: 5px;
  margin-bottom: 10px;
}

.view-table th, .edit-table th {
  background-color: #4a5568;
  border: 1px solid #64758a;
  padding: 4px 8px;
}

.view-table td, .edit-table td {
  border: 1px solid #64758a;
  padding: 4px 8px;
}

.edit-table td.entry > input, .edit-table td.entry > select, .edit-table td.entry > textarea {
  border: none;
  background-color: #2d3748;
  color: #cbd5e0;
  font-size: 1rem;
  margin: 0;
}

.edit-table td.entry > select, .edit-table td.entry > textarea {
  width: 100%;
}

.edit-table td.entry > textarea:focus {
  outline: none;
}

#team-table tr.team-data:hover {
  background-color: #1e2734;
  cursor: pointer;
}

#team-table th, #team-table td {
  text-align: left;
}

#team-table td:first-child, #team-table td:last-child {
  white-space: nowrap !important;
}

#clocking-form, #absences-form {
  display: none; /* flex */
  margin-top: 5px;
}

#report-table {
  margin-top: 15px;
  margin-bottom: 0;
}

.clickable {
  background-color: #4a5568;
}

.clickable:hover {
  background-color: #1e2734;
  cursor: pointer;
}

.clickable > div {
  display: flex;
  align-items: center;
  gap: 4px;
}

.clickable > div > .ti {
  font-size: 1.5rem;
  color: #fff;
}

.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 1000;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2rem;
}

.overlay > div {
  border: 1px solid #64758a;
  border-radius: 6px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  background-color: #2d3748;
  max-width: 400px;
  width: 80%;
  text-align: center;
  display: grid;
  gap: 0.5rem;
  padding: 20px;
}

.overlay > div[data-grid="false"] {
  display: block;
}

.separator {
  border-top: 1px solid #64758a;
}

.default-button {
  background-color: #4caf50;
  color: #fff;
  flex-shrink: 0;
  padding: 10px 20px;
}

.taLeft {
  text-align: left !important;
}

.taCenter {
  text-align: center !important;
}

.taRight {
  text-align: right !important;
}

.cursorForbidden:disabled {
  cursor: not-allowed;
}

.thickRow th, .thickRow td {
  padding-top: 16px;
  padding-bottom: 16px;
  font-weight: bold;
}

@media (orientation: portrait) {
  .menu {
    display: none !important;
  }
}

@media (min-width: 769px, orientation: landscape) {
  .menu {
    display: block !important;
  }
}

/* PC */
@media (min-width: 1025px) {
  .menu {
    position: sticky;
    top: 61px;
    height: calc(100vh - 61px);
    overflow-y: auto;
  }
  .content {
    overflow-y: auto;
  }
  #tasks-table th:not(:last-child) {
    white-space: wrap;
    width: 1%;
  }
}

/* Mobile and tablet vertical */
@media (max-width: 768px) {
  .content-box {
    padding: 1rem;
  }
}

/* Mobile and tablet */
@media (max-width: 1024px) {
  #schedule-table, #tasks-table {
    width: 100%;
    table-layout: fixed;
  }
  #schedule-table th, #schedule-table td {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  #tasks-table th, #tasks-table td {
    display: block;
    clear: both;
  }
  #tasks-table th:not(:last-child) {
    white-space: nowrap;
    text-align: left;
  }
}

/* Hack safari desktop */
@supports (-webkit-appearance: none) and (-webkit-hyphens: none) and (not (overflow:-webkit-marquee)) {
  select {
    -webkit-appearance: none;
    appearance: none;
  }
}

