:root {
  /* নতুন কালার প্যালেট - একটু ব্লু-ইশ এবং প্রিমিয়াম এমেরাল্ড গ্রিন */
  --primary: #0f766e; /* ডার্ক টিল/সবুজ */
  --primary-hover: #115e59;
  --bg-gradient: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%); /* হালকা নীলচে ব্যাকগ্রাউন্ড */
  --card-bg: #ffffff;
  --text-main: #1e293b;
  --text-muted: #64748b;
  --border-color: #e2e8f0;
  
  /* গ্লোয়িং শ্যাডো */
  --shadow-sm: 0 2px 4px rgba(15, 118, 110, 0.05);
  --shadow-md: 0 10px 25px -5px rgba(15, 118, 110, 0.15);
  --shadow-hover: 0 20px 25px -5px rgba(15, 118, 110, 0.2);
  
  --radius: 16px;
  --danger: #e11d48;
  --danger-hover: #be123c;
  --success: #059669;
  --warning: #d97706;
}

* { box-sizing: border-box; }
body { margin: 0; font-family: "Hind Siliguri", sans-serif; background: var(--bg-gradient); color: var(--text-main); min-height: 100vh; }

.wrap { width: min(1200px, 95%); margin: 40px auto; }
.back { display: inline-flex; align-items: center; gap: 5px; color: var(--primary); text-decoration: none; font-weight: 600; font-size: 0.95rem; margin-bottom: 20px; transition: 0.3s; background: #fff; padding: 8px 16px; border-radius: 30px; box-shadow: var(--shadow-sm); }
.back:hover { color: #fff; background: var(--primary); transform: translateX(-4px); }

.panel { background: var(--card-bg); border-radius: 24px; padding: 45px; box-shadow: var(--shadow-md); position: relative; border: 1px solid rgba(255, 255, 255, 0.5); backdrop-filter: blur(10px); }

/* Header */
.head { display: flex; gap: 20px; align-items: center; border-bottom: 2px dashed var(--border-color); padding-bottom: 25px; margin-bottom: 30px; }
.head img { width: 75px; height: 75px; border-radius: 50%; object-fit: cover; box-shadow: var(--shadow-md); border: 3px solid #fff; }
.head h1 { margin: 0; font-size: 2rem; color: #0f172a; font-weight: 700; letter-spacing: -0.5px; }
.head p { margin: 5px 0 0; color: var(--text-muted); font-size: 1.05rem; }

/* Forms & Inputs */
form { display: grid; gap: 18px; }
label { display: grid; gap: 8px; font-weight: 600; color: #334155; font-size: 0.95rem; }
input, textarea, select { width: 100%; padding: 12px 16px; border: 2px solid var(--border-color); border-radius: 10px; font: inherit; background: #f8fafc; transition: 0.3s; }
input:focus, select:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 4px rgba(15, 118, 110, 0.15); background: #fff; }

/* Buttons */
.btn { border: 0; background: var(--primary); color: #fff; border-radius: 10px; padding: 12px 24px; font: inherit; font-weight: 600; cursor: pointer; transition: 0.3s; display: inline-flex; align-items: center; justify-content: center; gap: 8px; box-shadow: var(--shadow-sm); }
.btn:hover { background: var(--primary-hover); transform: translateY(-2px); box-shadow: var(--shadow-md); }
.danger { background: linear-gradient(135deg, #f43f5e, #be123c); }
.danger:hover { background: linear-gradient(135deg, #e11d48, #9f1239); }
.secondary { background: #475569; }
.secondary:hover { background: #334155; }
.pdf { background: #6366f1; }
.pdf:hover { background: #4f46e5; }
.confirm { background: var(--success); }
.confirm:hover { background: #047857; }
.cancel { background: #f97316; }
.cancel:hover { background: #ea580c; }

/* Messages */
.message { display: none; padding: 16px 20px; border-radius: 12px; margin-bottom: 20px; font-weight: 500; animation: slideDown 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); }
@keyframes slideDown { from { opacity: 0; transform: translateY(-15px); } to { opacity: 1; transform: translateY(0); } }
.message.show { display: block; }
.message.ok { background: #ccfbf1; color: #0f766e; border-left: 5px solid var(--primary); }
.message.error { background: #ffe4e6; color: #be123c; border-left: 5px solid var(--danger); }

/* Hide elements logic */
[hidden], #userEmail, #noticeForm, #adminNotices, #noticesPanel { display: none !important; }

/* Dashboard Logout Header - Fixed Position */
.dash-head { position: absolute !important; top: 35px; right: 40px; width: auto !important; margin: 0 !important; padding: 0 !important; z-index: 20; display: flex !important;}
.dash-head #logout { min-width: 100px; padding: 10px 20px; border-radius: 10px; font-size: 1rem; box-shadow: 0 4px 15px rgba(225, 29, 72, 0.3); }

/* Stats Summary */
.summary { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin: 30px 0; }
.summary article { padding: 30px 20px; text-align: center; background: linear-gradient(to bottom, #ffffff, #f8fafc); border: 1px solid var(--border-color); border-radius: var(--radius); box-shadow: var(--shadow-sm); transition: 0.3s; }
.summary article:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); border-color: #cbd5e1; }
.summary b { font-size: 2.5rem; color: var(--primary); display: block; line-height: 1; margin-bottom: 10px; font-weight: 700; }
.summary span { display: block; color: var(--text-muted); font-size: 1rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; }

/* Modules Grid (Cards) */
.module-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin: 40px 0; }
.module-card { min-height: 140px; border: 1px solid var(--border-color); border-radius: var(--radius); background: #ffffff; color: var(--text-main); text-decoration: none; padding: 25px 15px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 14px; cursor: pointer; transition: all 0.4s ease; box-shadow: var(--shadow-sm); }
.module-card:hover { transform: translateY(-6px); border-color: var(--primary); box-shadow: var(--shadow-hover); background: #f0fdfa; }
.module-card strong { font-size: 1.2rem; color: #0f172a; font-weight: 700; }
.module-card small { font-size: 0.9rem; color: var(--text-muted); }

/* Modern Icons */
.module-icon { width: 60px; height: 60px; border-radius: 18px; display: grid; place-items: center; background: #e0f2fe; color: #0284c7; font-size: 1.8rem; transition: 0.3s; }
.module-card:hover .module-icon { background: var(--primary); color: #fff; transform: scale(1.1) rotate(-5deg); }

.module-card.notice-homework .module-icon { background: #ede9fe; color: #7c3aed; }
.module-card.notice-homework:hover .module-icon { background: #7c3aed; color: #fff; }
.module-card.finance-card .module-icon { background: #fef3c7; color: #d97706; }
.module-card.finance-card:hover .module-icon { background: #d97706; color: #fff; }

/* Application Items (Lists) */
.items { display: grid; gap: 20px; margin-top: 25px; }
.item { border: 1px solid var(--border-color); border-radius: var(--radius); padding: 25px; background: #fff; transition: 0.3s; box-shadow: var(--shadow-sm); }
.item:hover { box-shadow: var(--shadow-md); border-color: #cbd5e1; }
.item h3 { margin: 0 0 8px; font-size: 1.4rem; color: #0f172a; }
.item p { margin: 0 0 15px; color: var(--text-muted); font-size: 1rem; }
.item-actions { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 10px; margin-top: 20px; border-top: 1px dashed var(--border-color); padding-top: 20px; }

/* Status indicators */
.application.new { border-left: 6px solid var(--warning); }
.application.reviewed { border-left: 6px solid #6366f1; }
.application.confirmed { border-left: 6px solid var(--success); background: #f0fdf4; }
.application.cancelled { border-left: 6px solid var(--danger); background: #fff1f2; }

.meta { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; margin: 20px 0; background: #f8fafc; padding: 18px; border-radius: 12px; font-size: 1rem; }
.meta span b { color: #334155; font-weight: 600;}
.phone { color: var(--primary); font-weight: 700; text-decoration: none; display: flex; align-items: center; gap: 6px; }
.phone:hover { color: var(--primary-hover); text-decoration: underline; }

.status, .code { display: inline-flex; align-items: center; border-radius: 8px; padding: 6px 14px; font-size: 0.9rem; font-weight: 700; gap: 5px; }
.status.new { background: #fef3c7; color: #b45309; }
.status.reviewed { background: #e0e7ff; color: #4338ca; }
.status.confirmed, .code { background: #d1fae5; color: #047857; }
.status.cancelled { background: #ffe4e6; color: #be123c; }

/* Filters & Layout Utilities */
.dash-head, .actions, .section-title, .tools { display: flex; justify-content: space-between; align-items: center; gap: 15px; }
.filters { display: flex; gap: 10px; flex-wrap: wrap; margin: 25px 0; background: #f1f5f9; padding: 8px; border-radius: 12px; }
.filter { border: none; background: transparent; border-radius: 8px; padding: 10px 20px; font: inherit; font-weight: 600; cursor: pointer; color: var(--text-muted); transition: 0.3s; }
.filter:hover { background: #e2e8f0; color: var(--text-main); }
.filter.active { background: #fff; color: var(--primary); box-shadow: var(--shadow-sm); }

.tools input { flex: 1; max-width: 450px; }
.tools select { width: auto; min-width: 180px; }

/* Dialog / Modal */
dialog { width: min(550px, 92%); border: 0; border-radius: 20px; padding: 40px; box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.4); background: #fff; }
dialog::backdrop { background: rgba(15, 23, 42, 0.7); backdrop-filter: blur(5px); }
dialog h2 { margin-top: 0; color: #0f172a; border-bottom: 2px solid var(--border-color); padding-bottom: 15px; margin-bottom: 25px;}
dialog .actions { margin-top: 35px; justify-content: flex-end; }

/* Responsive */
@media(max-width:900px){ .module-grid { grid-template-columns: repeat(2, 1fr); } }
@media(max-width:720px){
  .panel { padding: 25px; }
  .summary { grid-template-columns: 1fr 1fr; }
  .dash-head { position: static !important; justify-content: flex-end !important; margin-bottom: 15px !important; }
  .section-title, .tools { align-items: stretch; flex-direction: column; }
  .tools select { max-width: none; }
  .meta { grid-template-columns: 1fr; }
}
@media(max-width:440px){
  .module-grid { grid-template-columns: 1fr; }
  .module-card { min-height: 100px; flex-direction: row; justify-content: flex-start; padding: 20px; text-align: left; }
  .module-card .module-icon { width: 50px; height: 50px; font-size: 1.4rem; margin-right: 15px;}
}