/* ========== OVERLAY STYLES ========== */
.overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(8px);
  z-index: 998;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.overlay.active {
  opacity: 1;
  visibility: visible;
}

/* ========== NOTIFICATION PANEL (Desktop default) ========== */
.notification-panel {
  position: fixed;
  top: 0;
  right: -420px;
  width: 400px;
  height: 100vh;
  background: linear-gradient(145deg, #ffffff 0%, #f8fafc 100%);
  box-shadow: -8px 0 40px rgba(0, 0, 0, 0.12);
  z-index: 999;
  display: flex;
  flex-direction: column;
  transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
  border-left: 1px solid rgba(226, 232, 240, 0.8);
}

.notification-panel.active {
  right: 0;
}

/* ========== PANEL HEADER ========== */
.panel-header {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 24px 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 2px 20px rgba(102, 126, 234, 0.15);
  position: relative;
  overflow: hidden;
}

.panel-header::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
  animation: float 8s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  50% { transform: translateY(-15px) rotate(180deg); }
}

.panel-header h2 {
  font-size: 22px;
  font-weight: 600;
  margin: 0;
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 12px;
}

.panel-header h2::before {
  content: '';
  font-size: 20px;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.1); }
}

/*  Actions container for header buttons */
.panel-header .actions {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px; 
  position: relative;
  z-index: 1;
}

/*  Shared button base */
.add-btn,
.close-btn {
  background: rgba(255, 255, 255, 0.15);
  border: 2px solid rgba(255, 255, 255, 0.25);
  color: white;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 18px;
  font-weight: 600;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}
.add-btn{
  margin-right: 110px;
}
.add-btn:hover,
.close-btn:hover {
  background: rgba(255, 255, 255, 0.25);
  transform: scale(1.05) translateY(-1px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.add-btn:active,
.close-btn:active {
  transform: scale(0.95);
}

/* ========== NOTICES CONTAINER ========== */
.notification-panel > *:not(.panel-header) {
  padding: 0 20px 20px 20px;
  flex: 1;
  overflow: hidden;
}

/* ========== NOTICE CARDS ========== */
.notice-card {
  background: white;
  border-radius: 16px;
  padding: 20px 24px;
  margin: 16px 0;
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.06);
  border: 1px solid rgba(226, 232, 240, 0.6);
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  position: relative;
  overflow: hidden;
  animation: slideInCard 0.5s ease-out;
}

@keyframes slideInCard {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.notice-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: linear-gradient(135deg, #667eea, #764ba2);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.notice-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 30px rgba(102, 126, 234, 0.12);
  border-color: rgba(102, 126, 234, 0.2);
}

.notice-card:hover::before {
  opacity: 1;
}

.notice-card h3 {
  font-size: 16px;
  font-weight: 600;
  color: #1e293b;
  margin: 0 0 12px 0;
  line-height: 1.4;
  display: flex;
  align-items: center;
  gap: 10px;
}

.notice-card h3::before {
  content: '•';
  color: #667eea;
  font-size: 20px;
  font-weight: bold;
}

.notice-content {
  color: #64748b;
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 16px;
}

.notice-content b {
  color: #667eea;
  cursor: pointer;
  font-weight: 600;
  transition: color 0.2s ease;
}

.notice-content b:hover {
  color: #5a67d8;
  text-decoration: underline;
}

/* ========== NOTICE FOOTER ========== */
.notice-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 8px;
  border-top: 1px solid #f1f5f9;
  font-size: 12px;
  margin-top: auto;
  flex-shrink: 0;
}

.notice-footer span:first-child {
  color: #94a3b8;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 6px;
}

.notice-footer span:first-child::before {
  content: '📅';
  font-size: 12px;
}

/* ========== MENU DROPDOWN ========== */
.menu {
  position: relative;
  cursor: pointer;
}

.menu .fa-ellipsis-h {
  color: #94a3b8;
  padding: 8px;
  border-radius: 8px;
  transition: all 0.2s ease;
}

.menu .fa-ellipsis-h:hover {
  background: #f1f5f9;
  color: #667eea;
}

.menu-dropdown {
  position: absolute;
  top: 100%;
  right: 0;
  background: white;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
  border: 1px solid #e2e8f0;
  min-width: 160px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px) scale(0.95);
  transition: all 0.2s cubic-bezier(0.25, 0.8, 0.25, 1);
  z-index: 10;
}

.menu-dropdown.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

.remove-notice {
  width: 100%;
  background: none;
  border: none;
  padding: 12px 16px;
  text-align: left;
  color: #ef4444;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  border-radius: 12px;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 8px;
}

.remove-notice:hover {
  background: #fef2f2;
  color: #dc2626;
}

/* ========== MODAL STYLES ========== */
.notice-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(8px);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.notice-modal-content {
  background: white;
  border-radius: 20px;
  padding: 32px;
  width: 90%;
  max-width: 480px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.15);
  animation: modalSlideIn 0.3s ease-out;
  position: relative;
  max-height: 90vh;
  overflow-y: auto;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: scale(0.9) translateY(-20px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

/* ========== RESPONSIVE (Mobile Bottom Drawer) ========== */
@media (max-width: 768px) {
  .notification-panel {
    top: auto;
    right: auto;
    bottom: -100%;
    left: 0;
    width: 100%;
    height: 70%;
    background: #fff;
    box-shadow: 0 -4px 12px rgba(0,0,0,0.2);
    border-top-left-radius: 12px;
    border-top-right-radius: 12px;
    transition: bottom 0.3s ease-in-out;
    z-index: 10000;
  }
  .notification-panel.active {
    bottom: 0;
  }
  .panel-header {
    padding: 16px;
  }
  .panel-header h2 {
    font-size: 16px;
  }
  .add-btn, .close-btn {
    width: 40px;
    height: 40px;
    font-size: 16px;
  }
}

.panel-header {
  display: flex;
  justify-content: space-between; 
  align-items: center;
}

.panel-header .actions {
  display: inline-flex;  
  align-items: center;
  justify-content: flex-end;
  gap: 10px;            
  flex-shrink: 0;        
}

.panel-header {
  position: relative; 
  display: flex;
  justify-content: flex-start; 
  align-items: center;
  padding-right: 60px; 
}

.close-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  margin: 0;
}
/* Modal background (hidden by default) */
.notice-modal {
  display: none; 
  position: fixed;
  z-index: 9998;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.5); 
}

/* Modal content box */
.notice-modal-content {
  background: #fff;
  margin: 10% auto;
  padding: 20px;
  border-radius: 10px;
  width: 90%;
  max-width: 400px;
  position: relative;
  z-index: 9999;
}

/* Cross button */
.close-btn {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 24px;
  font-weight: bold;
  color: #555;
  cursor: pointer;
}
.close-btn:hover {
  color: red;
}
 /* Center the action buttons */
.modal-actions {
  display: flex;
  justify-content: center;  
  gap: 12px;               
  margin-top: 15px;
}

/* Style for modal buttons */
.modal-actions button {
  min-width: 100px;
  padding: 8px 14px;
  font-size: 14px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  border: none;
}

/* Cancel button */
#cancelBtn {
  background-color: #333;
  color: white;
}

/* Save button */
.save-btn {
  background-color: #28a745;
  color: white;
}

.modal-actions button:hover {
  opacity: 0.85;
}
/* Style for modal buttons */
.modal-actions button {
  width: auto;           
  min-width: 100px;       
  padding: 8px 14px;
  font-size: 14px;
  border-radius: 6px;
  margin: 5px;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  display: inline-block;  
}

/* Cancel button */
#cancelBtn {
  background-color: #333;
  color: white;
}

/* Save button */
.save-btn {
  background-color: #28a745;
  color: white;
}

.modal-actions button:hover {
  opacity: 0.85;
}

/* Textarea fix */
.notice-modal-content textarea {
  width: 100%;
  min-height: 100px;
  padding: 8px;
  font-size: 14px;
  border: 1px solid #ccc;
  border-radius: 6px;
  resize: vertical;
  outline: none;
}
/* Ensure modal always appears above noticeboard */
.notice-modal {
  z-index: 11000;  
}

.notice-modal-content {
  position: relative;
  z-index: 11001; 
}
.tox-statusbar__branding{
  display: none;
}