/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

body {
  font-family: 'Segoe UI', 'Arial', sans-serif;
  font-size: 1.3rem;
  color: #1e2a46;
  margin: 0;
  padding: 0;
  min-height: 100vh;
  line-height: 1.6;
}

.main-header {
  display: flex;
  align-items: center;
  justify-content: space-between; /* pushes right-header to the right */
  background: linear-gradient(120deg, #1b46a7 0%, #407ef7 60%, #5a9bff 100%);
  padding: 1.5rem 2rem;
  margin-bottom: 2rem;
  box-shadow: 0 12px 24px rgba(26, 62, 155, 0.2);
  color: #fff;
}

.logo-img {
  height: 60px;
  width: auto;
  margin-right: 2rem;
  filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.2));
}

.daycare-title {
  font-size: 1.6rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.03em;
  font-family: inherit;
}

h1, h2, h3, h4, h5, h6 {
  color: #1f4fb9; /* Cobalt blue for all headings */
  margin-top: 0;
}

.main-content {
  max-width: 760px;
  margin: 0 auto 3rem;
  padding: 2.5rem;
  background: rgba(255, 255, 255, 0.92);
  border-radius: 1.25rem;
  box-shadow: 0 20px 40px rgba(30, 60, 130, 0.12);
  border: 1px solid rgba(101, 143, 227, 0.35);
  position: relative;
  overflow: hidden;
}

.main-content::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.main-content > * {
  position: relative;
  z-index: 1;
}

label, p, td, th, li, span, div, input, a {
  color: #1e2a46;
  font-size: 1.1rem;
}

form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  max-width: 100%;
  border-radius: 1rem;
  box-shadow: 0 16px 28px rgba(34, 76, 156, 0.08);
  border: 1px solid rgba(84, 132, 222, 0.25);
  padding: 1.5rem;
}

form label {
  font-size: 1.15rem;
  margin-bottom: 0.25rem;
}

form input[type="text"],
form input[type="password"] {
  font-size: 1.1rem;
  padding: 0.65rem 0.75rem;
  border-radius: 0.5rem;
  border: 1px solid rgba(90, 126, 210, 0.35);
  margin-bottom: 0.4rem;
  width: 100%;
  box-sizing: border-box;
  background: #ffffff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

form input[type="text"]:focus,
form input[type="password"]:focus {
  border-color: #3c7cff;
  outline: none;
  box-shadow: 0 0 0 3px rgba(70, 132, 255, 0.15);
}

form div {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

/* Style the button for better separation and look */
form input[type="submit"],
form button,
form input[type="button"] {
  font-size: 1.08rem;
  margin-top: 0.6rem;
  padding: 0.6rem 1.6rem;
  border-radius: 999px;
  background: linear-gradient(135deg, #1f57d6 0%, #3f8bff 100%);
  color: #fff;
  border: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  box-shadow: 0 12px 20px rgba(29, 79, 186, 0.2);
}
form input[type="submit"]:hover,
form button:hover,
form input[type="button"]:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 24px rgba(29, 79, 186, 0.24);
}

.inline-form {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.75rem;
  background: transparent;
  border: none;
  box-shadow: none;
  padding: 0;
  width: 100%;
}



.decline-reason-field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  width: 100%;
}

.decline-reason-label {
  font-size: 0.9rem;
  color: #1d2d5c;

}

.decline-reason-input {
  width: 100%;
  max-width: 100%;
  padding: 0.55rem 0.85rem;
  border-radius: 12px;
  border: 1px solid rgba(120, 160, 230, 0.45);
  font-size: 1rem;
  font-family: 'Segoe UI', 'Arial', sans-serif;
}

.decline-reason-input:focus {
  outline: none;
  border-color: #3f8bff;
  box-shadow: 0 0 0 3px rgba(63, 139, 255, 0.15);
}

.inline-label {
  margin: 0;
}

.inline-input {
  width: 5rem;
}

.small-help {
  font-size: 0.95rem;
  color: #555;
  margin-top: 0.15rem;
  margin-bottom: 0.3rem;
  line-height: 1.35;
  letter-spacing: 0.01em;
  font-style: italic;
  display: block;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 2rem;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 18px 32px rgba(30, 60, 130, 0.12);
  border-radius: 16px;
  overflow: hidden;
  font-size: 1.08rem;
  border: 1px solid rgba(120, 160, 230, 0.35);
}

.hours-table tbody tr {
  vertical-align: top;
}

.hours-table__date {
  white-space: nowrap;
}

.hours-table__detail {
  word-break: break-word;
}

.hours-table__hours {
  font-weight: 600;
  text-align: center;
}

.hours-table__status {
  text-align: left;
}

.status-wrapper {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  align-items: flex-start;
}

.status-reason {
  font-size: 0.95rem;
  color: #1f57d6;
  background: rgba(63, 139, 255, 0.08);
  padding: 0.35rem 0.6rem;
  border-radius: 8px;
}

.hours-table .action-buttons {
  padding: 0.35rem 0.9rem;
  font-size: 0.95rem;
  border-radius: 999px;
  box-shadow: none;
}


/* Table headers */
th {
  background: linear-gradient(120deg, #1d4fcc 0%, #3b82f6 100%);  /* cobalt blue */
  color: #fff;
  text-align: left;
  padding: 1rem 0.9rem;
  letter-spacing: 0.03em;
  font-weight: 600;
}

/* Table rows and cells */
td {
  padding: 0.95rem 0.9rem;
  border-bottom: 1px solid rgba(204, 216, 240, 0.8);
}

/* Alternate row color for readability */
tbody tr:nth-child(even) {
  background-color: rgba(237, 244, 255, 0.65);
}

/* Highlight row on hover */
tbody tr:hover {
  background-color: rgba(210, 229, 255, 0.8);
  transition: background 0.2s;
}

/* Optional: Actions column (e.g., Show link) */
td a {
  color: #1f57d6;
  text-decoration: none;
  font-weight: 500;
}

td a:hover {
  text-decoration: underline;
  color: #3f8bff;
}

/* Rounded corners for the table */
table,
table th:first-child,
table td:first-child {
  border-radius: 16px 0 0 16px;
}
table th:last-child,
table td:last-child {
  border-radius: 0 16px 16px 0;
}

.left-header {
  display: flex;
  align-items: center;
}

.right-header {
  display: flex;
  align-items: center;
  margin-left: auto;
  padding: 0.5rem 1rem;
  background-color: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  backdrop-filter: blur(4px);
}

.right-header a {
  color: #f5f8ff; /* cobalt blue */
  font-weight: 600;
  text-decoration: none;
  margin-left: 1rem;
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.right-header a:hover {
  background-color: rgba(255, 255, 255, 0.2);
  color: #fff;
  text-decoration: none;
}


.logout-link {
  font-size: 1.1rem;
  color: #f0f4ff;
  text-decoration: none;
  font-weight: 600;
}

.logout-link:hover {
  text-decoration: none;
}

table.small-table,
table.small-table td,
table.small-table th {
  font-size: 0.9rem !important; /* or whatever size you want */
}

.small-table tbody tr .inline-form {
  opacity: 0;
  max-height: 0;
  overflow: hidden;
  pointer-events: none;
  transition: opacity 0.2s ease, max-height 0.2s ease;
}

.small-table tbody tr:hover .inline-form,
.small-table tbody tr:focus-within .inline-form {
  opacity: 1;
  max-height: 500px;
  pointer-events: auto;
}


.hours-money-wrapper {
  display: flex;
  gap: 2rem;
  align-items: flex-start;
  flex-wrap: wrap;
}

input[disabled] {
  background-color: #eef3ff;
  cursor: not-allowed;
  color: rgba(30, 42, 70, 0.7);
}


@media (max-width: 600px) {
  body {
    font-size: 1.05rem;
  }

  .main-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
  }

  .right-header {
    width: 100%;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0.4rem 0.75rem;
  }

  .right-header a {
    margin-left: 0;
    font-size: 1rem;
  }

  .main-content {
    padding: 1.75rem 1.25rem;
    margin: 0 0.5rem 2.5rem;
  }

  table {
    display: block;
    overflow-x: auto;
  }

  table:not(.hours-table) th,
  table:not(.hours-table) td {
    font-size: 0.95rem;
    padding: 0.75rem 0.5rem;
  }

  table.hours-table {
    overflow: visible;
    border: none;
    box-shadow: none;
    background: transparent;
    margin-top: 1.25rem;
  }

  .hours-table thead {
    display: none;
  }

  .hours-table tbody tr {
    display: block;
    margin-bottom: 1rem;
    padding: 0.85rem 0.9rem;
    border-radius: 14px;
    border: 1px solid rgba(120, 160, 230, 0.4);
    box-shadow: 0 12px 24px rgba(30, 60, 130, 0.12);
    background: rgba(255, 255, 255, 0.98);
  }

  .hours-table td {
    display: block;
    padding: 0.45rem 0;
    font-size: 0.95rem;
    border: none;
  }

  .hours-table td::before {
    content: attr(data-label);
    display: block;
    font-weight: 600;
    color: #1f4fb9;
    margin-bottom: 0.15rem;
  }

  .hours-table__hours {
    text-align: left;
  }

  .status-wrapper {
    gap: 0.3rem;
  }

  .status-wrapper .action-buttons {
    align-self: flex-start;
  }
}
