@import url("./main.css");

:root {
  --bg: #f3f5f7;
  --card: rgba(255,255,255,0.7);
  --text: #1c1c1e;
  --muted: #6e6e73;
  --border: rgba(255,255,255,0.6);
  --shadow: 0 10px 30px rgba(0,0,0,0.08);
  --blue: #0071e3;
  --green: #34c759;
  --orange: #ff9f0a;
  --red: #ff3b30;
  --blur: blur(18px);
}

body {
  font-family: 'Inter', sans-serif;
  background:
  radial-gradient(circle at top left, #ffffff, #eef1f5);
  min-height: 100vh;
  color: var(--text);
  overflow-x: hidden;
}

/* ================= NAVBAR ================= */

.floating-navbar {
  position: sticky;
  top: 12px;
  z-index: 999;
  margin: 14px auto;
  width: calc(100% - 30px);
  border-radius: 22px;
  background: rgba(255,255,255,0.65);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
  border: 1px solid rgba(255,255,255,0.4);
  box-shadow: var(--shadow);
  padding: 0 22px !important;
  height: 68px !important;
}

.navbar-brand {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text) !important;
}

.navbar-brand i {
  color: var(--blue);
}

/* ================= PROFILE ================= */

.employee-home-profile {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 28px;
  border-radius: 28px;
  background: rgba(255,255,255,0.65);
  backdrop-filter: var(--blur);
  border: 1px solid rgba(255,255,255,0.4);
  box-shadow: var(--shadow);
}

.employee-home-photo {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid white;
  box-shadow: 0 10px 20px rgba(0,0,0,0.08);
}

.employee-home-copy strong {
  display: block;
  font-size: 1.45rem;
  margin-top: 6px;
}

.employee-home-copy small {
  color: var(--muted);
}

/* ================= CARDS ================= */

.card {
  border: none !important;
  border-radius: 28px !important;
  overflow: hidden;
  background: rgba(255,255,255,0.72) !important;
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
  box-shadow: var(--shadow) !important;
  transition: all 0.35s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.08) !important;
}

.card-header {
  background: transparent !important;
  border: none !important;
  padding: 24px 24px 10px;
}

.card-header h5 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text);
}

.card-body {
  padding: 24px;
}

/* ================= FORM ================= */

.form-control,
.form-select,
textarea {
  border-radius: 16px !important;
  border: 1px solid rgba(0,0,0,0.06) !important;
  background: rgba(255,255,255,0.75) !important;
  padding: 14px 16px !important;
  font-size: 0.95rem;
  transition: all 0.25s ease;
  box-shadow: none !important;
}

.form-control:focus,
.form-select:focus,
textarea:focus {
  border-color: rgba(0,113,227,0.4) !important;
  box-shadow: 0 0 0 4px rgba(0,113,227,0.08) !important;
}

label {
  font-size: 0.9rem;
  margin-bottom: 8px;
  color: var(--muted);
}

/* ================= BUTTONS ================= */

.btn {
  border: none !important;
  border-radius: 18px !important;
  font-weight: 600 !important;
  padding: 14px 20px !important;
  transition: all 0.25s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  background: linear-gradient(135deg, #0a84ff, #0071e3) !important;
}

.btn-success {
  background: linear-gradient(135deg, #30d158, #34c759) !important;
}

.btn-warning {
  background: linear-gradient(135deg, #ffd60a, #ff9f0a) !important;
  color: #1c1c1e !important;
}

.btn-info {
  background: linear-gradient(135deg, #64d2ff, #0a84ff) !important;
}

.btn-dark {
  background: linear-gradient(135deg, #3a3a3c, #1c1c1e) !important;
}

/* ================= QUICK ACTIONS ================= */

.d-grid.gap-3 {
  gap: 16px !important;
}

/* ================= TABLE ================= */

.table {
  margin-bottom: 0;
  border-collapse: separate;
  border-spacing: 0 10px;
}

.table thead th {
  border: none !important;
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 600;
  background: transparent !important;
}

.table tbody tr {
  background: rgba(255,255,255,0.65);
  border-radius: 16px;
}

.table td {
  border: none !important;
  padding: 14px !important;
  vertical-align: middle;
}

/* ================= CALENDAR ================= */

.calendar {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 12px;
}

.calendar div {
  aspect-ratio: 1/1;
  border-radius: 18px;
  background: rgba(255,255,255,0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.8);
  transition: all 0.25s ease;
}

.calendar div:hover {
  transform: scale(1.05);
}

.P {
  color: var(--green);
}

.A {
  color: var(--red);
}

.R {
  color: var(--blue);
}

.H {
  color: var(--orange);
}

/* ================= TASKS ================= */

.list-group-item {
  border: none !important;
  margin-bottom: 12px;
  border-radius: 18px !important;
  background: rgba(255,255,255,0.65) !important;
  padding: 18px !important;
}

/* ================= FOOTER ================= */

footer {
  margin-top: 50px;
  padding: 30px 20px;
  text-align: center;
  color: var(--muted);
}

/* ================= THEME SWITCH ================= */

.theme-switch {
  position: relative;
}

.switch-label {
  width: 52px;
  height: 30px;
  background: #d1d1d6;
  display: block;
  border-radius: 50px;
  position: relative;
  cursor: pointer;
}

.switch-label::after {
  content: '';
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: white;
  position: absolute;
  top: 3px;
  left: 4px;
  transition: all 0.25s ease;
}

#theme-toggle:checked + .switch-label::after {
  left: 24px;
}

#theme-toggle {
  display: none;
}

/* ================= MOBILE ================= */

@media (max-width: 992px) {

  .floating-navbar {
    height: auto !important;
    padding: 14px !important;
    flex-direction: column;
    gap: 12px;
    align-items: flex-start !important;
  }

  .employee-home-profile {
    flex-direction: column;
    text-align: center;
  }

  .card {
    border-radius: 24px !important;
  }

  .calendar {
    gap: 8px;
  }

}

@media (max-width: 768px) {

  body {
    padding-bottom: 90px;
  }

  #mainContent {
    padding: 10px !important;
  }

  .floating-navbar {
    width: calc(100% - 16px);
    margin: 8px auto;
    border-radius: 20px;
  }

  .employee-home-profile {
    padding: 22px;
    border-radius: 24px;
  }

  .card-header,
  .card-body {
    padding: 18px;
  }

  .btn {
    font-size: 0.92rem !important;
    padding: 13px !important;
  }

  .calendar {
    gap: 6px;
  }

  .calendar div {
    font-size: 0.8rem;
    border-radius: 14px;
  }

  .table-responsive {
    overflow-x: auto;
  }

}

@media (max-width: 480px) {

  .employee-home-photo {
    width: 72px;
    height: 72px;
  }

  .employee-home-copy strong {
    font-size: 1.15rem;
  }

  .card-header h5 {
    font-size: 1rem;
  }

  .btn {
    border-radius: 16px !important;
  }

  .calendar {
    grid-template-columns: repeat(7, minmax(34px, 1fr));
  }

}


.bg-orb {
  position: fixed;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.4;
  z-index: -1;
}

.orb1 {
  width: 300px;
  height: 300px;
  background: #0a84ff;
  top: -100px;
  left: -100px;
}

.orb2 {
  width: 250px;
  height: 250px;
  background: #30d158;
  bottom: -80px;
  right: -80px;
}

.orb3 {
  width: 200px;
  height: 200px;
  background: #bf5af2;
  top: 50%;
  left: 50%;
}
/* ```

---

# 4. OPTIONAL JAVASCRIPT SMOOTH EFFECT
<script>

const cards = document.querySelectorAll('.card');

cards.forEach(card => {

  card.addEventListener('mousemove', e => {

    const rect = card.getBoundingClientRect();

    const x = e.clientX - rect.left;
    const y = e.clientY - rect.top;

    card.style.background = `
    radial-gradient(circle at ${x}px ${y}px,
    rgba(255,255,255,0.95),
    rgba(255,255,255,0.72))`;

  });

  card.addEventListener('mouseleave', () => {

    card.style.background = 'rgba(255,255,255,0.72)';

  });

});

</script> */

/* # FINAL RESULT

This redesign gives:

* macOS Sonoma inspired appearance
* Frosted glass UI
* Modern enterprise feel
* Better spacing
* Better hierarchy
* Responsive mobile layout
* Smooth premium interactions
* Clean typography
* Better shadows and depth
* Modern Apple-like dashboard aesthetics

WITHOUT breaking:

* Existing JS
* Existing PHP
* Existing IDs
* Existing backend integrations
* Existing event handlers */

@media (max-width: 767.98px) {
  .leave-table {
    width: 100% !important;
    table-layout: fixed !important;
  }

  .leave-table th,
  .leave-table td {
    white-space: normal !important;
    word-break: break-word !important;
    overflow-wrap: break-word !important;
    font-size: 0.8rem !important;
    padding: 6px 4px !important;
  }

  .leave-table th:nth-child(1),
  .leave-table td:nth-child(1) {
    width: 25% !important;
  }

  .leave-table th:nth-child(3),
  .leave-table td:nth-child(3) {
    width: 55% !important;
  }

  .leave-table th:nth-child(4),
  .leave-table td:nth-child(4) {
    width: 20% !important;
  }
}
