:root {
  --primary: #003366;
  --primary-hover: #002244;
  --accent: #4a90e2;
  --neutral-100: #f8f9fa;
  --neutral-200: #e9ecef;
  --neutral-300: #dee2e6;
  --neutral-800: #343a40;
}

body {
  background: url("../img/bc4.jpg");
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
}

/* ================= Layout ================= */

.page-container {
  width: 90%;
  max-width: 1500px;
  margin: 32px auto;
  display: flex;
  gap: 25px;
}

.left-panel {
  width: 300px;
  min-height: 780px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.9);
  padding: 30px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.right-panel {
  flex: 1;
  min-height: 780px;
}

/* ================= avatar box ================= */

#admin-avatar {
  width: 110px;
  height: 110px;
  border-radius: 50%;
  border: 4px solid var(--primary);
  object-fit: cover;
  cursor: pointer;
}

#username {
  margin-top: 14px;
  font-size: 24px;
  font-weight: 800;
}

/* ============== left menu ============== */

.tab-btn-box {
  width: 100%;
  margin-top: 40px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.tab-btn {
  padding: 12px 16px;
  border-radius: 10px;
  cursor: pointer;
  width: 100%;
  font-size: 18px;
  transition: all 0.3s;
  color: var(--primary);
  font-weight: 700;
}

.tab-btn:hover {
  background: rgba(0, 0, 0, 0.08);
}

.tab-btn.active {
  background-color: var(--primary-hover);
  color: white;
}

/* ================= Right Content ================= */

.panel-content {
  display: none;
}

.panel-content.active {
  display: block;
}

.section-box {
  background: rgba(255, 255, 255, 0.9);
  padding: 20px;
  border-radius: 14px;
  border: 1px solid var(--neutral-300);
  margin-top: 24px;
  transition: all 0.3s ease;
}

.section-box:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

/* ================= Component : Section Title ================= */

.section-title {
  width: 140px;
  border-bottom: 3px solid var(--primary);
  margin-bottom: 18px;
}

.section-title h4 {
  margin: 0;
  font-size: 24px;
  color: var(--primary-hover);
}

/* ================= profile grid ================= */

.info-grid {
  margin-top: 6px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px 18px;
  background: rgba(0, 0, 0, 0.08);
  border-radius: 10px;
  padding: 16px 20px;
}

.info-item {
  position: relative;
  display: flex;
  align-items: center;
  color: var(--primary-hover);
  font-size: 17px;

  border: 1px solid transparent;
  border-radius: 6px;
  transition: all 0.25s;
}

.info-item:hover {
  border-color: #4482bc;
  background: rgba(0, 0, 0, 0.03);
}

/* 固定右侧 */
.info-actions {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);

  display: flex;
  align-items: center;
  gap: 8px;

  opacity: 0;
  transition: all 0.25s;
}

.value {
  font-weight: 600;
  color: #001a33;
  border-radius: 4px;
}

.info-item:hover .info-actions {
  opacity: 1;
}

.icon-btn {
  cursor: pointer;
  transition: all 0.25s;
}

.icon-btn:hover {
  transform: scale(1.07);
}

.edit {
  width: 28px;
  height: 28px;
}

.flash {
  width: 24px;
  height: 24px;
}

.flash:hover {
  content: url("./icon/flash_hover.svg");
}

.edit:hover {
  content: url("./icon/info_edit_hover.svg");
}

.fade-in {
  animation: fadeInUp 0.35s ease both;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.table {
  border-collapse: separate !important;
  border-spacing: 0 10px !important;
}

.table thead tr th {
  border: none;
  color: var(--primary-hover);
  font-weight: 600;
  font-size: 16px;
}

.table tbody tr {
  background: rgba(255, 255, 255, 0.7);
  border: #4482bc 1px solid;
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.25s ease;
}

.table tbody tr td {
  border: none;
  padding: 14px 18px !important;
  font-size: 15px;
  color: #003;
}

/* hover 效果 */
.table tbody tr:hover {
  background: rgba(0, 0, 0, 0.06);
  transform: translateY(-4px);
  box-shadow: 0px 6px 18px rgba(0, 0, 0, 0.18);
}

.paginator {
  display: flex;
  justify-content: center;
  margin-top: 18px;
  gap: 6px;
}

.page-btn {
  padding: 6px 12px;
  border-radius: 6px;
  border: 1px solid rgba(0, 0, 0, 0.15);
  background: rgba(255, 255, 255, 0.8);
  font-size: 15px;
  cursor: pointer;
  transition: all 0.25s;
}

.page-btn:hover {
  background: rgba(0, 0, 0, 0.06);
}

.page-btn.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

@media (max-width: 768px) {
  #username {
    display: none;
  }

  #admin-avatar {
    width: 70px;
    height: 70px;
    margin-left: 0px;
    border-radius: 50%;
    border: 4px solid var(--primary);
    object-fit: cover;
    cursor: pointer;
  }

  .page-container {
    flex-direction: column;
    width: 96%;
    margin-top: 16px;
    gap: 10px;
  }

  .left-panel {
    width: 100%;
    min-height: auto;
    padding: 16px 10px;
    flex-direction: row;
    /* justify-content: space-around; */
  }

  #admin-avatar {
    width: 70px;
    height: 70px;
    border-width: 2px;
    margin-left: -10px;
  }

  #username {
    font-size: 18px;
    margin-top: 4px;
  }

  .tab-btn-box {
    margin-left: 20px;
    flex-direction: row;
    width: auto;
    margin-top: 0;
    gap: 6px;
  }

  .tab-btn {
    font-size: 14px;
    padding: 6px 8px;
    white-space: nowrap;
  }

  .right-panel {
    width: 100%;
  }

  .section-box {
    margin-top: 14px;
    padding: 14px;
  }

  .info-grid {
    grid-template-columns: 1fr;
    padding: 12px;
  }

  .info-item {
    font-size: 15px;
    padding-right: 50px;
  }

  .info-actions {
    right: 8px;
  }
}
