/* styles.css - Complete Styling for Mercy Model School Parent and Admin Pages */
/* Pixel-perfect match design images - purple cards, icons, responsive grids */

:root {
  --purple: #6a1b9a;
  --purple-light: #9c4dcc;
  --blue: #1976d2;
  --green: #4caf50;
  --orange: #ff9800;
  --red: #f44336;
  --gray: #f5f5f5;
  --white: #fff;
  --bg: #FDF6FB;               /* Very light pinkish */
  --surface: #FFFFFF;
  --main: #00008B;             /* Dark blue from logo */
  --accent: #FF69B4;           /* Hot pink from shield */
  --text: #00008B;             /* Dark blue for text */
  --muted: #4A4A4A;            /* Gray for secondary text */
  --shadow: 0 4px 20px rgba(0,0,0,0.1);
  --radius: 16px;
  --transition: all 0.3s ease;

  /* Additional semantic colors - kept these as they are used in some components */
  --primary: #1E3A8A;
  --primary-light: #3b82f6;
  --warning: #CFA43B;
  --success: #10b981;
  --danger: #ef4444;
}


* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  line-height: 1.6;
  color: var(--text);
  background: linear-gradient(180deg, var(--bg), #f1f5f9);
  transition: background 0.3s, color 0.3s;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

html body section.container {
  width: 100%;
  min-width: 100%;
  padding: 0;
  margin: 0;
  border-radius: 0;
}

/* Data Reveal Animation */
[data-reveal] {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity .6s, transform .6s;
}
[data-reveal].revealed {
  opacity: 1;
  transform: translateY(0);
}

/* -------------------------
   Sections
   ------------------------- */
section { margin-bottom: 0; }
h1, h2, h3, h4 { font-weight: 700; color: var(--main); }
h1 { font-size: 2.5rem; margin-bottom: 16px; }
h2 { font-size: 2rem; }

.page-hero {
  text-align: center;
  padding: 60px 0;
  background: linear-gradient(var(--purple), var(--purple-light)), url('../images/hero-bg.jpg');
  color: white;
  border-radius: var(--radius);
}
.page-hero h1 { font-size: 2rem; color: var(--bg); }
.page-hero p { margin: auto 10px; }

/* --- BRAND ROW --- */
.brand {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 4%;
  background: var(--main);
}
.brand-logo img {
  height: 42px;
  width: auto;
}

/* ------------------
    Header 
   ------------------ */
.main-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--surface);
  box-shadow: 0 8px 32px rgba(0,0,139,0.15);
}

/* Hide scrollbar */
.main-header .main-nav::-webkit-scrollbar { display: none; }

.main-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  padding: 8px 5%;
  position: relative;
}

.hamburger-dark {
  display: flex;
  color: var(--purple);     
  align-items: center;
  gap: 20px;
  flex: 0 0 auto;
}

.nav-link-container {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 1;
  justify-content: center;
}

.nav-link {
  white-space: nowrap;
  font-size: 15px;
  padding: 10px 12px;
  color: var(--purple);
  text-decoration: none;
  font-weight: 500;
  position: relative;
  transition: all .25s ease;
  scrollbar-width: none;
}
.nav-link.active, .offcanvas-links.active {
  color: var(--text);
  font-weight: 700;
  background: rgba(255,105,180,0.15);
}
.main-nav .nav-link:hover, .offcanvas-links a:hover {
  color: var(--purple-light);
  background: rgba(255,105,180,0.1);
}
.no-hover { pointer-events: none; }

.nav-link.active::after, .offcanvas-links.active::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 60%;
  height: 4px;
  background: var(--text);
  border-radius: 2px;
  transform: translateX(-50%);
  transition: width 0.3s ease;
}
.main-nav .nav-link:hover::after { width: 80%; }

#hamburger {
  color: var(--text) !important; 
  font-size: 1.5rem; 
  background: none; 
  border: none; 
  cursor: pointer; 
  padding: 0.25rem 0.5rem;
  display: flex !important;
  align-items: center;
  justify-content: center;
  z-index: 10;
}

#darkToggle { 
  background: none; 
  border: none; 
  font-size: 1.2rem; 
  cursor: pointer; 
}

.brand-search {
  position: relative;
  display: flex;
  align-items: center;
  flex: 0 0 auto;
}
.brand-search input {
  width: 240px;
  padding: 8px 38px 8px 14px;
  border-radius: 999px;
  border: 1px solid rgba(0,0,0,.2);
  background: transparent;
  color: var(--text);              /* Fixed typo: var(-tex) → var(--text) */
  transition: all .3s ease;
}
.siteSearchBtn {
  position: absolute;
  right: 6px;
  background: none;
  border: none;
  cursor: pointer;
  font-size: 18px;
  color: var(--accent);
}
.search-close {
  display: none;
  position: absolute;
  right: 6px;
  font-size: 18px;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--danger);
}
.brand-search button:hover {
  transform: scale(1.05);
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.6);
}
.brand-search:focus-within input {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px rgba(212,175,55,0.25);
}

/* ---- SEARCH RESULTS POPUP ---- */
.search-results {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  width: min(420px, 92vw);
  max-height: 320px;
  overflow-y: auto;
  background: var(--surface);
  border-radius: 8px;
  box-shadow: var(--shadow);
  padding: 8px;
  z-index: 120;
}
.search-history {
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(0,0,0,0.08);
  margin-bottom: 8px;
}
#historyList .hist-item {
  padding: 6px;
  border-radius: 6px;
  cursor: pointer;
  color: var(--muted);
}
#historyList .hist-item:hover {
  background: rgba(30,58,138,0.05);
}
.search-result-item {
  padding: 8px;
  border-radius: 6px;
  cursor: pointer;
}
.search-result-item:hover,
.search-result-item:focus {
  background: rgba(30,58,138,0.06);
}

/* ---- MOBILE REFINEMENTS ---- */
@media (max-width:767px) {
  .brand { padding: .6rem calc(2rem); display: none; }
  .brand-search input { width:10%; max-width: 120px; opacity:0; pointer-events:none; }
  body.search-open .brand-search input { width:100%; opacity:1; pointer-events:auto; }
  body.search-open .siteSearchBtn { display:none; }
  body.search-open .search-close { display:block; }
  body.search-open .nav-link-container {
    opacity:0; pointer-events:none;
  }
  body.search-open .hamburger-dark {
    opacity:0; pointer-events:none;
  }
  .nav-link-container .extra-link,
  .extra-link { display: none !important; }
}

/* -------------------------
   Offcanvas styles
   ------------------------- */
.offcanvas {
  position: fixed;
  top: 0;
  left: -100%;
  width: 80%;
  max-width: 320px;
  min-height: 100svh;
  height: auto;
  background: white;
  z-index: 2000;
  overflow: auto;
  transition: left 0.3s ease;
  box-shadow: 2px 0 10px rgba(0,0,0,0.1);
  display: block;
}

.offcanvas.open { 
  left: 0; 
}

.offcanvas[aria-hidden="false"] {
  left: 0;
}

.offcanvas[aria-hidden="true"] {
  left: -100%;
}

/* Offcanvas overlay */
.offcanvas-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  min-height: 100svh;
  height: auto;
  background: rgba(0,0,0,0.5);
  z-index: 1999;
  opacity: 0;
  inset: 0;
  transition: all 0.3s ease;
  pointer-events: none;
}

.offcanvas-overlay.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* Hide offcanvas by default on desktop */
@media (min-width: 769px) {
  .offcanvas {
    left: -100% !important;
  }
  
  .offcanvas-overlay {
    display: none !important;
  }

  /* Hide hamburger on large screens */
  .hamburger-dark {
    display: none !important;
  }
}
.offcanvas-inner {
  background: var(--surface);
  flex: 1;
  overflow: auto;
  width: fit-content;
  min-width: 100%;
}

.offcanvas-body {
  background: white;
  flex: 1;
  overflow-y: auto;
  padding: 0;
}

.offcanvas-close {
  color: white;
  font-size: 1.5rem;
  background: rgba(255,255,255,0.2);
  border-radius: 50%;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
}

.offcanvas-close:hover {
  background: rgba(255,255,255,0.3);
}

/* ===================================
   RESPONSIVE IMPROVEMENTS
   =================================== */
/* Parent Navigation Responsive Improvements */
@media (max-width: 768px) {
  .parent-header-img {
    display: none !important;
  }
  
  .nav-link-container {
    display: none !important;
  }
  
  .hamburger-dark {
    display: flex !important;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 0.5rem 1rem;
  }
  
  .hamburger-dark .school-name {
    display: block !important;
    color: white;
    font-size: 1.1rem;
    font-weight: 600;
  }
  .school-name {color: var(--purple) !important; text-decoration: none;}
  
  #hamburger {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
  }
}

@media (max-width: 480px) {
  .hamburger-dark {
    padding: 0.5rem;
  }
  
  .hamburger-dark .school-name {
    font-size: 1rem;
  }
}

.offcanvas-top {
  background: var(--main);
  color: white;
  padding: 1rem;
  position: sticky;
  top: 0;
  z-index: 10;
}

.offcanvas-top-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.offcanvas-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.offcanvas-logo img {
  width: 40px;
  height: 40px;
}

.offcanvas-logo .school-name {
  font-size: 1.1rem;
  font-weight: 600;
}

.offcanvas-body {
  background: white;
  padding: 0;
  flex: 1;
  overflow-y: auto;
}

.offcanvas-links {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1rem;
  list-style: none;
  margin: 0;
  pointer-events: auto;
  position: relative;
  z-index: 10;
}

.offcanvas-links a,
.offcanvas-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  color: var(--main);
  text-decoration: none;
  border-radius: 8px;
  transition: all 0.3s ease;
  font-weight: 500;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(0,0,139,0.1);
  position: relative;
  z-index: 20;
  cursor: pointer;
  pointer-events: auto;
}

.offcanvas-links a:hover,
.offcanvas-link:hover {
  background: rgba(255,105,180,0.1);
  color: var(--accent);
  transform: translateX(4px);
}

.offcanvas-links a.active,
.offcanvas-link.active {
  background: rgba(255,105,180,0.2);
  color: var(--accent);
  font-weight: 600;
  border-color: rgba(255,105,180,0.3);
}

.offcanvas-links a .nav-icon,
.offcanvas-link .nav-icon {
  font-size: 1.2rem;
  width: 24px;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.offcanvas-links a.logout-link,
.offcanvas-link.logout-link {
  color: var(--danger);
  border-color: rgba(220, 38, 38, 0.2);
}

.offcanvas-links a.logout-link:hover,
.offcanvas-link.logout-link:hover {
  background: rgba(220, 38, 38, 0.1);
  color: var(--danger);
}

/* Contact Page Styles */
.contact-section {
  margin: 3rem 0;
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}

.contact-info h2 {
  color: var(--main);
  margin-bottom: 1rem;
  font-size: 2rem;
}

.contact-info p {
  margin-bottom: 2rem;
  line-height: 1.6;
  color: var(--muted);
}

.contact-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 2rem;
}

.contact-icon {
  font-size: 2rem;
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent);
  color: white;
  border-radius: 50%;
  flex-shrink: 0;
}

.contact-details h3 {
  color: var(--main);
  margin-bottom: 0.5rem;
  font-size: 1.2rem;
}

.contact-details p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.contact-form {
  background: white;
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.contact-form h2 {
  color: var(--main);
  margin-bottom: 1.5rem;
  font-size: 1.8rem;
}

.contact-form-inner {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.form-group {
  display: flex;
  flex-direction: column;
}

.form-group label {
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: var(--main);
}

.form-group input,
.form-group select,
.form-group textarea {
  padding: 1rem;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  font-size: 1rem;
  transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent);
}

.btn-primary {
  background: var(--accent);
  color: white;
  padding: 1rem 2rem;
  border: none;
  border-radius: 8px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.btn-primary:hover {
  background: #ff1493;
}

/* FAQ Section */
.faq-section {
  margin: 4rem 0;
}

.faq-section h2 {
  color: var(--main);
  margin-bottom: 2rem;
  font-size: 2rem;
  text-align: center;
}

.faq-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.faq-item {
  background: white;
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.faq-item h3 {
  color: var(--main);
  margin-bottom: 1rem;
  font-size: 1.3rem;
}

.faq-item p {
  color: var(--muted);
  line-height: 1.6;
}

/* Emergency Section */
.emergency-section {
  margin: 4rem 0;
}

.emergency-section h2 {
  color: var(--main);
  margin-bottom: 2rem;
  font-size: 2rem;
  text-align: center;
}

.emergency-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.emergency-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: #fff3e0;
  padding: 1.5rem;
  border-radius: var(--radius);
  border-left: 5px solid var(--orange);
}

.emergency-icon {
  font-size: 2rem;
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--orange);
  color: white;
  border-radius: 50%;
  flex-shrink: 0;
}

.emergency-details h3 {
  color: var(--main);
  margin-bottom: 0.5rem;
  font-size: 1.2rem;
}

.emergency-details p {
  margin: 0;
  color: var(--muted);
  font-weight: 600;
}

/* Responsive Design */
@media (max-width: 768px) {
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  
  .contact-form {
    padding: 1.5rem;
  }
  
  .faq-grid {
    grid-template-columns: 1fr;
  }
  
  /*.emergency-grid {
    grid-template-columns: 1fr;
  }*/
  .emergency-item {
  display: flex;
  align-items: center;
  gap: .8rem;
  background: #fff3e0;
  padding: 1.1rem;
  border-radius: var(--radius);
  border-left: 4px solid var(--orange);
}
}

@media (max-width: 480px) {
  .contact-info h2,
  .faq-section h2,
  .emergency-section h2 {
    font-size: 1.5rem;
  }
  
  .contact-form {
    padding: 1rem;
  }
  
  .faq-item,
  .emergency-item {
    padding: 1rem;
  }
}

/* Parent Header Responsive */
@media (max-width: 768px) {
  .parent-header {
    padding: 1rem 0 !important;
    flex-direction: column;
    text-align: center;
    gap: 1rem;
  }
  
  .parent-avatar {
    width: 60px !important;
    height: 60px !important;
    margin: 0 auto;
  }
  
  .parent-info {
    text-align: center;
  }
  
  .parent-info h1 {
    font-size: 1.8rem !important;
  }
  
  .session-info {
    font-size: 1rem !important;
  }
}

@media (max-width: 480px) {
  .parent-header {
    padding: 0.75rem 0 !important;
  }
  
  .parent-avatar {
    width: 50px !important;
    height: 50px !important;
  }
  
  .parent-info h1 {
    font-size: 1.5rem !important;
  }
  
  .session-info {
    font-size: 0.9rem !important;
  }
}

/* Children Cards Responsive */
@media (max-width: 768px) {
  .children-grid {
    grid-template-columns: 1fr !important;
    gap: 1.5rem !important;
  }
  
  .child-card {
    text-align: center !important;
    padding: 1.5rem !important;
  }
  
  .child-avatar {
    margin: 0 auto 1rem auto !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
  }
  
  .child-avatar img,
  .child-avatar .avatar-placeholder {
    margin: 0 auto !important;
  }
  
  .child-avatar {
    width: 50px !important;
    height: 50px !important;
  }
  
  .child-avatar .avatar-placeholder {
    font-size: 1.5rem !important;
  }
  
  .child-card h3 {
    font-size: 1.2rem !important;
  }
  
  .child-card .class {
    font-size: 0.9rem !important;
  }
  
  .fee-details {
    gap: 0.5rem !important;
  }
  
  .fee-item {
    flex-direction: column;
    gap: 0.25rem !important;
  }
  
  .fee-item span {
    font-size: 0.85rem !important;
  }
  
  .fee-item strong {
    font-size: 0.9rem !important;
  }
  
  .pay-btn {
    width: 100% !important;
    margin-top: 1rem !important;
  }
}

@media (max-width: 480px) {
  .children-grid {
    gap: 0.8rem !important;
  }
  
  .child-card {
    padding: 1rem !important;
  }
  
  .child-avatar {
    width: 40px !important;
    height: 40px !important;
  }
  
  .child-avatar .avatar-placeholder {
    font-size: 1.2rem !important;
  }
  
  .child-card h3 {
    font-size: 1.1rem !important;
  }
  
  .child-card .class {
    font-size: 0.85rem !important;
  }
  
  .status-badge {
    font-size: 0.75rem !important;
    padding: 0.4rem 0.8rem !important;
  }
}

/* Quick Actions Responsive */
@media (max-width: 768px) {
  .quick-actions-grid {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
  }
  
  .action-card {
    padding: 1.2rem !important;
  }
  
  .action-icon {
    width: 40px !important;
    height: 40px !important;
  }
  
  .action-icon svg {
    width: 20px !important;
    height: 20px !important;
  }
  
  .action-content h4 {
    font-size: 1rem !important;
  }
  
  .action-content p {
    font-size: 0.85rem !important;
  }
}

@media (max-width: 480px) {
  .quick-actions {
    margin: 2rem 0 !important;
  }
  
  .quick-actions-grid {
    gap: 0.8rem !important;
  }
  
  .action-card {
    padding: 1rem !important;
  }
  
  .action-icon {
    width: 36px !important;
    height:  36px !important;
  }
  
  .action-icon svg {
    width: 18px !important;
    height: 18px !important;
  }
  
  .action-content h4 {
    font-size: 0.9rem !important;
  }
  
  .action-content p {
    font-size: 0.8rem !important;
  }
}

/* Payment Page Responsive */
@media (max-width: 768px) {
  .payment-card {
    padding: 1.5rem !important;
  }
  
  .student-summary {
    flex-direction: column !important;
    gap: 1rem !important;
    text-align: center !important;
  }
  
  .student-info {
    text-align: center !important;
  }
  
  .student-avatar-img {
    margin: 0 auto;
    display: block;
  }
  
  .avatar-placeholder {
    width: 60px !important;
    height: 60px !important;
    font-size: 2rem !important;
    margin: 0 auto;
  }
  
  .fee-breakdown {
    margin-top: 1rem !important;
  }
  
  .payment-methods {
    margin: 1.5rem 0 !important;
  }
  
  .payment-options-grid {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
  }
  
  .payment-option {
    padding: 1rem !important;
    flex-direction: column !important;
    text-align: center !important;
  }
  
  .payment-icon {
    margin: 0 auto 1rem !important;
  }
  
  .payment-info {
    text-align: center !important;
  }
  
  .payment-badge {
    position: static !important;
    margin-top: 0.5rem !important;
    right: auto !important;
    top: auto !important;
  }
}

@media (max-width: 480px) {
  .payment-card {
    padding: 1rem !important;
  }
  
  .student-summary .avatar-placeholder {
    width: 50px !important;
    height: 50px !important;
    font-size: 1.5rem !important;
  }
  
  .student-info h2 {
    font-size: 1.2rem !important;
  }
  
  .student-info p {
    font-size: 0.9rem !important;
  }
  
  .fee-breakdown h3 {
    font-size: 1.3rem !important;
  }
  
  .fee-row {
    padding: 0.6rem !important;
  }
  
  .fee-row strong {
    font-size: 0.9rem !important;
  }
  
  .payment-option {
    padding: 0.8rem !important;
  }
  
  .payment-icon {
    width: 36px !important;
    height: 36px !important;
  }
  
  .payment-icon svg {
    width: 18px !important;
    height: 18px !important;
  }
  
  .payment-badge {
    font-size: 0.7rem !important;
    padding: 0.2rem 0.6rem !important;
  }
}

/* Payment History Responsive */
@media (max-width: 768px) {
  .filter-card {
    padding: 1.5rem !important;
  }
  
  .form-grid {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
  }
  
  .form-group {
    margin-bottom: 1rem !important;
  }
  
  .form-group label {
    font-size: 0.9rem !important;
  }
  
  .form-group select {
    padding: 0.6rem !important;
    font-size: 0.9rem !important;
  }
}

@media (max-width: 480px) {
  .filter-card {
    padding: 1rem !important;
  }
  
  .form-grid {
    gap: 0.8rem !important;
  }
  
  .form-group {
    margin-bottom: 0.8rem !important;
  }
  
  .form-group label {
    font-size: 0.85rem !important;
  }
  
  .form-group select {
    padding: 0.5rem !important;
    font-size: 0.85rem !important;
  }
}

/* Receipt Page Responsive */
@media (max-width: 768px) {
  .receipt-container {
    padding: 1.5rem !important;
    margin: 0 1rem !important;
  }
  
  .receipt-header {
    margin-bottom: 1.5rem !important;
  }
  
  .receipt-header h2 {
    font-size: 1.5rem !important;
  }
  
  .receipt-table {
    font-size: 0.9rem !important;
  }
  
  .receipt-table th,
  .receipt-table td {
    padding: 0.6rem !important;
  }
  
  .receipt-actions {
    flex-direction: column !important;
    gap: 0.8rem !important;
  }
}

@media (max-width: 480px) {
  .receipt-container {
    padding: 1rem !important;
    margin: 0 0.5rem !important;
  }
  
  .receipt-header {
    margin-bottom: 1rem !important;
  }
  
  .receipt-header h2 {
    font-size: 1.3rem !important;
  }
  
  .receipt-table {
    font-size: 0.8rem !important;
  }
  
  .receipt-table th,
  .receipt-table td {
    padding: 0.4rem !important;
  }
  
  .receipt-actions {
    gap: 0.6rem !important;
  }
  
  .receipt-actions .btn-primary,
  .btn-secondary {
    width: 100% !important;
  }
}

/* -------------------------
    Footer
    ------------------------ */
.footer-link {
  color: inherit;
  text-decoration: none;
}

.footer-link:hover {
  text-decoration: underline;
}

/* Footer Responsive */
@media (max-width: 768px) {
  .footer {
    padding: 1rem 0 !important;
  }
  
  .footer p {
    font-size: 0.85rem !important;
  }
}

@media (max-width: 480px) {
  .footer {
    padding: 0.75rem 0 !important;
  }
  
  .footer p {
    font-size: 0.8rem !important;
  }
}

@media (min-width: 1024px) {
  .container { max-width:1200px; padding:24px 0; }
  h1 { font-size:3rem; }
}

.header-inner { align-items:flex-start; gap:12px; }
.main-nav { margin-top:8px; }

/* ================================
   BACK TO TOP – PROGRESS RING
   ================================ */
.progress-btn {
  position: fixed;
  right: 20px;
  bottom: 24px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--surface);
  border: none;
  cursor: pointer;
  display: grid;
  place-items: center;
  box-shadow: 0 12px 28px rgba(0,0,0,0.25);
  opacity: 0;
  visibility: hidden;
  transform: translateY(18px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  z-index: 1500;
}
.progress-btn.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.progress-ring { position: absolute; inset: 0; transform: rotate(-90deg); }
.progress-ring-bg { fill: none; stroke: rgba(0,0,0,0.08); stroke-width: 4; }
.progress-ring-circle {
  fill: none;
  stroke: var(--purple);
  stroke-width: 4;
  stroke-linecap: round;
  stroke-dasharray: 138;
  stroke-dashoffset: 138;
  transition: stroke-dashoffset 0.15s linear;
}
.chevron-icon {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: var(--text);
  stroke-width: 2.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  z-index: 1;
}
.progress-btn:hover .chevron-icon { animation: chevronJump 0.45s ease; }
@keyframes chevronJump {
  0% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
  100% { transform: translateY(0); }
}
@media (max-width: 767px) {
  .progress-btn { width: 48px; height: 48px; right: 16px; bottom: 18px; }
}

/* ===============================
   Form Styling for Registration Page
   ============================== */
.form-section-title {
  background: var(--purple-light);
  color: var(--white);
  padding: 1rem;
  border-radius: var(--radius) var(--radius) 0 0;
  margin: 2rem 0 0 0;
  text-align: center;
  font-size: 1.4rem;
}
.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  padding: 2rem;
  align-items: center;
}
.form-group {
  display: flex;
  flex-direction: column;
}
.form-group label {
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: var(--purple);
}
.form-group input,
.form-group select,
.form-group textarea {
  padding: 12px;
  border: 1px solid #ccc;
  border-radius: 8px;
  font-size: 1rem;
  transition: border 0.3s;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--purple);
  box-shadow: 0 0 0 3px rgba(106, 27, 154, 0.1);
}
#tuition_group { transition: all 0.25s ease-in-out; } 
.full-width { grid-column: 1 / -1; }
.optional { font-weight: normal; color: var(--muted); font-size: 0.9rem; }
.btn-primary.large { width: 100%; padding: 16px; font-size: 1.2rem; margin-top: 2rem; }

/* Consolidated btn-primary (latest version overrides earlier ones) */
.btn-primary {
  background: var(--purple-light);
  color: var(--white);
  padding: 12px 30px;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 600;
  display: inline-block;
  transition: var(--transition);
}
.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}
.btn-primary.large {
  padding: 16px 40px;
  font-size: 1.2rem;
}
.btn-small {
  background: var(--purple-light);
}

/* Sections */
.section h2 {
  text-align: center;
  font-size: 2.5rem;
  margin-bottom: 3rem;
  color: var(--purple);
}

/* Process Grid (4 steps) */
.process-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}
.process-card {
  background: var(--white);
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  text-align: center;
  position: relative;
}
.process-card .step {
  position: absolute;
  top: -20px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--blue);
  color: var(--white);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
}
.process-card img { width: 80px; margin: 1rem 0; }
.process-card h3 { margin: 1rem 0; color: var(--purple); }
.highlight { border: 3px solid var(--purple-light); }

/* Highlight Boxes */
.highlight-box {
  background: var(--gray);
  padding: 2rem;
  border-radius: var(--radius);
  text-align: center;
  margin: 2rem 0;
}
.highlight-box.orange { background: #fff3e0; border-left: 5px solid var(--orange); }

/* Dashboard Preview & Children Grid - merged latest version */
.dashboard-preview,
.children-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
  margin: 3rem 0;
}
.child-card {
  background: var(--white);
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  text-align: center;
  transition: var(--transition);
  border-left: 6px solid transparent;     /* Fixed typo: border-leftt6px */
}
.child-card:hover { transform: translateY(-8px); }
.child-card.paid { border-left-color: var(--green); }
.child-card.partial { border-left-color: var(--orange); }
.child-card.unpaid { border-left-color: var(--red); }
.child-card img,
.child-avatar img { width: 100px; margin-bottom: 1rem; }
.avatar-medium {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid #eee;
}
.child-card h3 { margin: 0.5rem 0; font-size: 1.4rem; }
.class { color: var(--purple); font-weight: 600; margin-bottom: 1.5rem; }

/* Fee details */
.fee-info,
.fee-details {
  background: var(--gray);
  padding: 1.5rem;
  border-radius: var(--radius);
  margin: 1.5rem 0;
}
.fee-item { display: flex; justify-content: space-between; margin: 0.8rem 0; font-size: 1.1rem; }
.fee-total { display: flex; justify-content: space-between; font-size: 1.2rem; font-weight: bold; padding-top: 0.8rem; border-top: 1px solid #ddd; margin-top: 0.8rem; }
.fee-balance { display: flex; justify-content: space-between; color: var(--red); font-weight: bold; }
.fee-balance.zero { color: var(--green); }

/* Status badges - merged latest version */
.status,
.status-badge {
  padding: 12px;
  border-radius: 50px;
  font-weight: bold;
  margin: 1.5rem 0;
  font-size: 1.1rem;
}
.status.green,
.status-badge.green { background: #e8f5e8; color: var(--green); }
.status.orange,
.status-badge.orange { background: #fff3e0; color: var(--orange); }
.status.red,
.status-badge.red { background: #ffebee; color: var(--red); }

/* Payment Options */
.payment-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin: 3rem 0;
}
.payment-card {
  margin: 2rem 0;
  background: var(--white);
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  text-align: center;
} /* Fixed: removed stray "*}" */
.payment-card img { width: 100px; margin-bottom: 1rem; }

.badge {
  display: inline-block;
  padding: 8px 20px;
  border-radius: 50px;
  font-weight: bold;
  margin-top: 1rem;
}
.badge.green { background: #e8f5e8; color: var(--green); }
.badge.orange { background: #fff3e0; color: var(--orange); }

.protection-box {
  background: var(--green);
  color: var(--white);
  padding: 2rem;
  border-radius: var(--radius);
  text-align: center;
  margin: 3rem 0;
}

/* Benefits Grid */
.benefits-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
}
.benefit-card {
  background: var(--white);
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  text-align: center;
  border-left: 5px solid var(--purple-light);
}
.benefit-card img { width: 80px; margin-bottom: 1rem; }

/* Special Grid */
.special-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}
.special-card {
  background: #f3e5f5;
  padding: 2rem;
  border-radius: var(--radius);
  text-align: center;
}
.special-card img { width: 80px; margin-bottom: 1rem; }

/* Users Grid */
.users-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 2rem;
}
.user-card {
  background: linear-gradient(135deg, var(--purple), var(--purple-light));
  color: var(--white);
  padding: 2rem;
  border-radius: var(--radius);
  text-align: center;
}
.user-card img { width: 80px; margin-bottom: 1rem; }
.user-card ul { text-align: left; margin-top: 1rem; }
.user-card li { margin: 0.8rem 0; }

/* CTA */
.cta {
  text-align: center;
  padding: 4rem 0;
  background: linear-gradient(135deg, var(--purple-light), var(--purple));
  color: var(--white);
  border-radius: var(--radius);
  margin: 4rem 0;
}
.cta h2 { font-size: 2.5rem; margin-bottom: 1rem; }

/* Footer */
.footer {
  background: var(--purple);
  color: var(--white);
  text-align: center;
  padding: 2rem 0;
  margin-top: 4rem;
}

/* Responsive */
@media (max-width: 768px) {
  .hero h1 { font-size: 2.2rem; }
  .section h2 { font-size: 2rem; }
  .process-grid,
  .dashboard-preview,
  .payment-grid,
  .benefits-grid,
  .special-grid,
  .users-grid,
  .children-grid {
    grid-template-columns: 1fr;
  }
}

/* Enrollment Status (Admin Registration) */
.checkbox-label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  cursor: pointer;
}
.checkbox-label input[type="checkbox"] {
  width: 18px;
  height: 18px;
  cursor: pointer;
}
.hint {
  display: block;
  margin-top: 6px;
  font-size: 0.85rem;
  color: #666;
}

/* Login Page Specific Styles */
.login-hero {
  background: linear-gradient(135deg, var(--purple), var(--purple-light));
  color: var(--white);
  text-align: center;
  padding: 4rem 2rem;
  border-radius: var(--radius);
  margin-bottom: 3rem;
}
.login-hero h1 { font-size: 2.8rem; margin-bottom: 1rem; }
.login-hero p { font-size: 1.2rem; opacity: 0.95; }
.login-form { max-width: 480px; margin: 0 auto; }
.form-options {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 1.5rem 0;
  flex-wrap: wrap;
  gap: 1rem;
}
.checkbox-label {
  display: flex;
  align-items: center;
  font-size: 0.95rem;
  cursor: pointer;
  color: var(--text);
}
.checkbox-label input { opacity: 0; position: absolute; }
.checkmark {
  width: 20px;
  height: 20px;
  border: 2px solid #ccc;
  border-radius: 4px;
  margin-right: 8px;
  transition: var(--transition);
}
.checkbox-label input:checked ~ .checkmark {
  background: var(--purple);
  border-color: var(--purple);
}
.checkmark:after {
  content: "✓";
  color: white;
  font-weight: bold;
  display: none;
  margin: 2px 0 0 4px;
}
.checkbox-label input:checked ~ .checkmark:after { display: block; }
.forgot-link {
  color: var(--purple);
  text-decoration: none;
  font-size: 0.95rem;
}
.forgot-link:hover { text-decoration: underline; }
.login-footer {
  text-align: center;
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid #eee;
  color: var(--muted);
}
.login-footer p { margin: 0.8rem 0; }
.link { color: var(--purple); font-weight: 600; }

/* Trust Section */
.trust-section { margin: 4rem 0; }
.trust-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  text-align: center;
}
.trust-item .icon { font-size: 3rem; display: block; margin-bottom: 1rem; }
.trust-item p { line-height: 1.5; }

/* Parent Dashboard Enhancements */
.parent-header {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  background: linear-gradient(135deg, var(--purple-light), var(--purple));
  color: white;
  padding: 2rem;
  border-radius: var(--radius);
  margin: 2rem 0;
}
.avatar-large {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid white;
  box-shadow: var(--shadow);
}

.parent-avatar-img,
.child-avatar-img,
.student-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.parent-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(255,105,180,0.3);
}
.avatar-placeholder {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: rgba(255,255,255,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 4rem;
  color: white;
}
.parent-info h1 { font-size: 2.2rem; margin-bottom: 0.5rem; }
.session-info { font-size: 1.2rem; margin: 0.5rem 0; opacity: 0.9; }

/* Quick Actions */
.quick-actions {
  margin: 3rem 0;
}

.quick-actions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  max-width: 800px;
  margin: 0 auto;
}

.action-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 1.5rem;
  background: rgba(255,255,255,0.1);
  border-radius: var(--radius);
  border: 2px solid rgba(255,255,255,0.2);
  text-decoration: none;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.action-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(255,105,180,0.1), rgba(0,0,139,0.1));
  opacity: 0;
  transition: opacity 0.3s ease;
}

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

.action-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0,0,139,0.2);
  border-color: rgba(255,105,180,0.3);
}

.action-icon {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, var(--main), var(--accent));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  color: white;
  box-shadow: 0 4px 16px rgba(0,0,139,0.3);
}

.action-icon svg {
  width: 24px;
  height: 24px;
  color: white;
}

.action-content h4 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--main);
  margin: 0;
  line-height: 1.3;
}

.action-content p {
  font-size: 0.9rem;
  color: var(--text);
  margin: 0;
  line-height: 1.4;
}

/* Responsive Design */
@media (max-width: 768px) {
  .quick-actions-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .action-card {
    padding: 1.2rem;
  }
  
  .action-icon {
    width: 40px;
    height: 40px;
  }
  
  .action-content h4 {
    font-size: 1rem;
  }
  
  .action-content p {
    font-size: 0.85rem;
  }
}

@media (max-width: 480px) {
  .quick-actions {
    margin: 2rem 0;
  }
  
  .quick-actions-grid {
    gap: 0.8rem;
  }
  
  .action-card {
    padding: 1rem;
  }
  
  .action-icon {
    width: 36px;
    height: 36px;
  }
  
  .action-content h4 {
    font-size: 0.9rem;
  }
  
  .action-content p {
    font-size: 0.8rem;
  }
}

/* Payment Methods */
.payment-methods {
  margin: 2rem 0;
}

.payment-methods h3 {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--main);
  margin-bottom: 1.5rem;
  text-align: center;
}

.payment-options-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.payment-option {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.5rem;
  background: rgba(255,255,255,0.05);
  border: 2px solid rgba(255,255,255,0.1);
  border-radius: var(--radius);
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
}

.payment-option:hover {
  background: rgba(255,255,255,0.1);
  border-color: rgba(255,105,180,0.3);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0,0,139,0.2);
}

.payment-option.active {
  background: rgba(255,105,180,0.1);
  border-color: var(--accent);
  box-shadow: 0 4px 16px rgba(255,105,180,0.2);
}

.payment-icon {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, var(--main), var(--accent));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  box-shadow: 0 4px 12px rgba(0,0,139,0.3);
  flex-shrink: 0;
}

.payment-icon svg {
  width: 24px;
  height: 24px;
  color: white;
}

.payment-info {
  flex: 1;
}

.payment-info h4 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--main);
  margin: 0 0 0.5rem 0;
}

.payment-info p {
  font-size: 0.9rem;
  color: var(--text);
  margin: 0;
  line-height: 1.4;
}

.payment-badge {
  position: absolute;
  top: -10px;
  right: 15px;
  background: linear-gradient(135deg, var(--accent), var(--main));
  color: white;
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(255,105,180,0.3);
}

/* Responsive Design */
@media (max-width: 768px) {
  .payment-options-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .payment-option {
    padding: 1.2rem;
  }
  
  .payment-icon {
    width: 40px;
    height: 40px;
  }
  
  .payment-icon svg {
    width: 20px;
    height: 20px;
  }
  
  .payment-info h4 {
    font-size: 1rem;
  }
  
  .payment-info p {
    font-size: 0.85rem;
  }
}

@media (max-width: 480px) {
  .payment-option {
    padding: 1rem;
    gap: 0.8rem;
  }
  
  .payment-icon {
    width: 36px;
    height: 36px;
  }
  
  .payment-icon svg {
    width: 18px;
    height: 18px;
  }
  
  .payment-badge {
    top: -8px;
    right: 10px;
    font-size: 0.7rem;
    padding: 0.2rem 0.6rem;
  }
}

/* Payment History Enhancements */
.payment-history-table {
  background: rgba(255,255,255,0.05);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0,0,139,0.1);
}

.payment-history-table table {
  width: 100%;
  border-collapse: collapse;
}

.payment-history-table th {
  background: linear-gradient(135deg, var(--main), var(--accent));
  color: white;
  padding: 1rem;
  text-align: left;
  font-weight: 600;
}

.payment-history-table td {
  padding: 1rem;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

.payment-history-table tr:hover {
  background: rgba(255,255,255,0.05);
}

.payment-status {
  display: inline-block;
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
}

.payment-status.completed {
  background: rgba(34,197,94,0.2);
  color: #22c55e;
  border: 1px solid rgba(34,197,94,0.3);
}

.payment-status.pending {
  background: rgba(251,146,60,0.2);
  color: #fb923c;
  border: 1px solid rgba(251,146,60,0.3);
}

/* Receipt Enhancements */
.receipt-container {
  background: white;
  border-radius: var(--radius);
  box-shadow: 0 8px 32px rgba(0,0,139,0.15);
  padding: 2rem;
  max-width: 800px;
  margin: 0 auto;
}

.receipt-header {
  text-align: center;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid rgba(0,0,139,0.1);
}

.receipt-header h2 {
  color: var(--main);
  font-size: 1.8rem;
  margin: 0;
}

.receipt-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
}

.receipt-table th {
  background: rgba(0,0,139,0.05);
  padding: 0.8rem;
  text-align: left;
  font-weight: 600;
  color: var(--main);
}

.receipt-table td {
  padding: 0.8rem;
  border-bottom: 1px solid rgba(0,0,139,0.05);
}

.receipt-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin-top: 2rem;
}

/* Global Search */
.search-section {
  display: none;
  background: #f0e6ff;
  padding: 1.2rem 0;
  text-align: center;
  border-bottom: 1px solid #e0d4f5;
}
.global-search {
  position: relative;
  max-width: 900px;
  margin: 0 auto;
  display: flex;
  justify-content: center;
}
.global-search input {
  width: 100%;
  max-width: 800px;
  padding: 12px 60px 12px 20px;
  height: 52px;
  font-size: 1rem;
  border: 2px solid var(--purple);
  border-radius: 50px;
  background: white;
  outline: none;
  transition: border-color 0.3s, box-shadow 0.3s;
}
.global-search input:focus {
  border-color: var(--purple-light);
  box-shadow: 0 0 0 4px rgba(106, 27, 154, 0.15);
}
.global-search button {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  background: var(--purple);
  color: white;
  border: none;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s;
}
.global-search button:hover { background: var(--purple-light); }
.global-search button::before { content: "🔍"; }
.search-hint {
  margin-top: 0.8rem;
  color: var(--muted);
  font-style: italic;
  font-size: 0.95rem;
}
@media (max-width: 768px) {
  .global-search input { height: 50px; padding: 12px 58px 12px 18px; font-size: 1.05rem; }
  .global-search button { width: 40px; height: 40px; font-size: 1.2rem; }
}
@media (max-width: 480px) {
  .search-section .container { padding: 0 0.8rem; }
  .global-search input { height: 48px; font-size: 1rem; }
}

/* Admin Stats - merged & kept latest responsive version */
.admin-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin: 3rem 0;
  justify-content: center;
}
.admin-stats .stat-card {
  flex: 1 1 180px;
  background: white;
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  text-align: center;
  transition: var(--transition);
}
.admin-stats .stat-card:hover { transform: translateY(-5px); }
.large-number {
  font-size: 3rem;
  font-weight: bold;
  color: var(--purple);
  margin: 1rem 0;
}
.stat-card.green .large-number { color: var(--green); }
.stat-card.orange .large-number { color: var(--orange); }
.stat-card.red .large-number { color: var(--red); }
@media (min-width: 768px) {
  .admin-stats { flex-wrap: nowrap; justify-content: space-between; gap: 2rem; }
  .admin-stats .stat-card { flex: 1; max-width: none; }
  .large-number { font-size: 3.2rem; }
}
@media (min-width: 1200px) {
  .large-number { font-size: 3.5rem; }
}

/* Registration Page - Photo upload */
.photo-upload { grid-column: 1 / -1; text-align: center; margin-bottom: 2rem; }
.photo-preview {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  overflow: hidden;
  margin: 1rem auto;
  border: 4px solid var(--purple-light);
  box-shadow: var(--shadow);
}
.photo-preview img { width: 100%; height: 100%; object-fit: cover; }
input[type="file"] {
  display: block;
  margin: 1rem auto;
  padding: 1rem;
  background: #f8f9fa;
  border: 2px dashed var(--purple);
  border-radius: var(--radius);
  width: 100%;
  max-width: 400px;
}

/* Fees Management Page */
.fees-table {
  width: 100%;
  border-collapse: collapse;
  margin: 2rem 0;
}
.fees-table th {
  background: var(--purple);
  color: white;
  padding: 1rem;
  text-align: left;
}
.fees-table td { padding: 1rem; border-bottom: 1px solid #eee; }
.fees-table input {
  width: 100%;
  padding: 0.8rem;
  border: 1px solid #ccc;
  border-radius: 6px;
}
.sss-row { background: #f3e5f5; }
.sss-row.science { background: #e8f5e8; font-weight: 600; }
.note-box {
  background: #fff3e0;
  padding: 1.5rem;
  border-radius: var(--radius);
  border-left: 5px solid var(--orange);
  margin: 2rem 0;
}
.table-responsive { overflow-x: auto; }

/* Analysis Page */
.analysis-summary { margin-bottom: 4rem; }
.stat-card.large { padding: 3rem; }
.stat-card.large .large-number { font-size: 4rem; }
.percentage { font-size: 1.8rem; margin-top: 1rem; opacity: 0.8; }
.charts-section { margin: 4rem 0; }
.chart-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 3rem;
}
.chart-card {
  background: white;
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.chart-card.full-width { grid-column: 1 / -1; }
canvas { max-height: 400px; }
.print-btn {
  margin: 2rem 0;
  padding: 12px 30px;
  font-size: 1.1rem;
}
.insights-section { margin: 4rem 0; }
.insights-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
}
.insight-card {
  background: white;
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border-left: 5px solid var(--purple-light);
}
.insight-card h4 { color: var(--purple); margin-bottom: 1rem; }

/* Records Page */
.tabs-section { margin: 3rem 0; }
.tabs {
  display: flex;
  gap: 1rem;
  border-bottom: 2px solid #eee;
  margin-bottom: 1.5rem;
}
.tab-btn {
  padding: 0.6rem 1.2rem;
  background: #eee;
  border: none;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  transition: var(--transition);
}
.tab-btn.active {
  color: #fff;
  background: var(--purple);
  border-bottom: 4px solid var(--purple-light);
}
.tab-content { display: none; }
.tab-content.active { display: block; }
.records-table {
  width: 100%;
  border-collapse: collapse;
}
.records-table th,
.records-table td {
  padding: 0.75rem;
  border-bottom: 1px solid #ddd;
}
.table-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
}
.status-badge {
  padding: 0.25rem 0.6rem;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 600;
}
.status-badge.green { background: #e6f4ea; color: #1e7e34; }
.status-badge.red { background: #fdecea; color: #b71c1c; }
.status-badge.orange { background: #fff4e5; color: #a15c00; }