/* ============================================================
   Swarnamali Girls College - Global Stylesheet
   Theme: Forest Green + Gold + White
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;600;700&family=Inter:wght@300;400;500;600;700&display=swap');

:root {
  --green-900: #1B5E20; --green-800: #2E7D32; --green-700: #388E3C;
  --green-600: #43A047; --green-500: #4CAF50; --green-400: #66BB6A;
  --green-100: #E8F5E9; --green-50: #F1F8F1;
  --gold: #F9A825; --gold-light: #FFF8E1;
  --white: #FFFFFF; --gray-50: #FAFAFA; --gray-100: #F5F5F5;
  --gray-200: #EEEEEE; --gray-300: #E0E0E0; --gray-500: #9E9E9E;
  --gray-700: #616161; --gray-900: #212121;
  --danger: #C62828; --danger-light: #FFEBEE;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 20px rgba(0,0,0,0.12);
  --shadow-lg: 0 8px 40px rgba(0,0,0,0.16);
  --radius-sm: 8px; --radius-md: 14px; --radius-lg: 20px; --radius-xl: 28px;
  --transition: 0.3s cubic-bezier(0.4,0,0.2,1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: 'Inter', sans-serif; color: var(--gray-900); background: var(--white); line-height: 1.6; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--green-800); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--green-600); }
ul { list-style: none; }
h1,h2,h3,h4,h5,h6 { font-family: 'Playfair Display', serif; line-height: 1.3; color: var(--green-900); }
h1 { font-size: clamp(2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.5rem); }
h3 { font-size: clamp(1.2rem, 2vw, 1.8rem); }
p { color: var(--gray-700); }

/* ---- NAVBAR ---- */
.navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  background: rgba(27,94,32,0.97); backdrop-filter: blur(12px);
  padding: 0 5%; display: flex; align-items: center;
  justify-content: space-between; height: 70px;
  box-shadow: 0 2px 20px rgba(0,0,0,0.3); transition: all var(--transition);
}
.nav-brand { display: flex; align-items: center; gap: 12px; }
.nav-brand img { height: 44px; width: 44px; border-radius: 50%; border: 2px solid var(--gold); }
.nav-brand .brand-name { font-family: 'Playfair Display', serif; font-size: 1rem; font-weight: 700; color: var(--white); }
.nav-brand .brand-sub { font-size: 0.65rem; color: var(--gold); letter-spacing: 1px; text-transform: uppercase; }
.nav-links { display: flex; align-items: center; gap: 4px; }
.nav-links a { color: rgba(255,255,255,0.85); font-size: 0.875rem; font-weight: 500; padding: 8px 14px; border-radius: var(--radius-sm); transition: all var(--transition); }
.nav-links a:hover, .nav-links a.active, .nav-links a.nav-active { color: var(--white); background: rgba(255,255,255,0.15); }
.nav-links a.nav-active { background: rgba(255,255,255,0.22); color: var(--gold) !important; font-weight: 700; }
.nav-links .btn-login { background: var(--gold); color: var(--green-900) !important; font-weight: 700; padding: 8px 20px; border-radius: 50px; margin-left: 8px; }
.nav-links .btn-login:hover { background: #FFC107; transform: translateY(-1px); }
.nav-toggle { display: none; flex-direction: column; gap: 5px; cursor: pointer; padding: 4px; }
.nav-toggle span { display: block; width: 24px; height: 2px; background: var(--white); border-radius: 2px; transition: all var(--transition); }

/* ---- HERO ---- */
.hero {
  min-height: 100vh;
  background: linear-gradient(135deg, var(--green-900) 0%, var(--green-700) 50%, var(--green-500) 100%);
  display: flex; align-items: center; justify-content: center;
  text-align: center; padding: 100px 5% 60px; position: relative; overflow: hidden;
}
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(255,255,255,0.15); border: 1px solid rgba(255,255,255,0.2);
  color: var(--gold); font-size: 0.8rem; font-weight: 600; letter-spacing: 2px; text-transform: uppercase;
  padding: 8px 20px; border-radius: 50px; margin-bottom: 24px; animation: fadeInDown 0.8s ease;
}
.hero-title { color: var(--white); margin-bottom: 16px; text-shadow: 0 2px 20px rgba(0,0,0,0.3); animation: fadeInUp 0.9s ease; }
.hero-subtitle { font-size: 1.1rem; color: rgba(255,255,255,0.85); max-width: 600px; margin: 0 auto 16px; font-family: 'Playfair Display', serif; font-style: italic; animation: fadeInUp 1s ease; }
.hero-motto { color: var(--gold); font-size: 1rem; font-weight: 600; letter-spacing: 2px; margin-bottom: 40px; animation: fadeInUp 1.1s ease; }
.hero-buttons { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; animation: fadeInUp 1.2s ease; }
.hero-stats { display: flex; gap: 40px; justify-content: center; flex-wrap: wrap; margin-top: 50px; animation: fadeInUp 1.3s ease; }
.hero-stat .num { font-family: 'Playfair Display', serif; font-size: 2.5rem; font-weight: 700; color: var(--gold); }
.hero-stat .lbl { font-size: 0.8rem; color: rgba(255,255,255,0.7); letter-spacing: 1px; text-transform: uppercase; }

/* ---- BUTTONS ---- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 28px; border-radius: 50px; font-size: 0.9rem; font-weight: 600;
  cursor: pointer; border: none; outline: none; transition: all var(--transition); text-decoration: none;
}
.btn-primary { background: var(--gold); color: var(--green-900); }
.btn-primary:hover { background: #FFC107; transform: translateY(-2px); box-shadow: 0 6px 20px rgba(249,168,37,0.5); color: var(--green-900); }
.btn-outline { background: transparent; color: var(--white); border: 2px solid rgba(255,255,255,0.6); }
.btn-outline:hover { background: rgba(255,255,255,0.15); border-color: var(--white); color: var(--white); }
.btn-green { background: var(--green-700); color: var(--white); }
.btn-green:hover { background: var(--green-800); transform: translateY(-2px); box-shadow: 0 6px 20px rgba(56,142,60,0.4); color: var(--white); }
.btn-sm { padding: 8px 18px; font-size: 0.8rem; }
.btn-danger { background: var(--danger); color: var(--white); }
.btn-danger:hover { background: #B71C1C; color: var(--white); }
.btn-gold { background: var(--gold); color: var(--green-900); }

/* ---- SECTIONS ---- */
.section { padding: 80px 5%; }
.section-alt { background: var(--green-50); }
.section-dark { background: var(--green-900); }
.section-header { text-align: center; margin-bottom: 60px; }
.section-tag { display: inline-block; font-size: 0.75rem; font-weight: 700; letter-spacing: 2px; text-transform: uppercase; color: var(--green-700); margin-bottom: 12px; padding: 4px 16px; background: var(--green-100); border-radius: 50px; }
.section-header h2 { margin-bottom: 12px; }
.section-header p { color: var(--gray-500); max-width: 550px; margin: 0 auto; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 28px; }
.grid-4 { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 24px; }
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(360px, 1fr)); gap: 32px; }

/* ---- CARDS ---- */
.card { background: var(--white); border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); overflow: hidden; transition: transform var(--transition), box-shadow var(--transition); }
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.card-img { width: 100%; height: 200px; object-fit: cover; }
.card-body { padding: 24px; }
.card-tag { font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; color: var(--green-700); background: var(--green-100); padding: 3px 12px; border-radius: 50px; display: inline-block; margin-bottom: 10px; }
.card-title { font-size: 1.1rem; color: var(--green-900); margin-bottom: 8px; }
.card-text { font-size: 0.875rem; color: var(--gray-700); line-height: 1.6; }
.card-meta { font-size: 0.75rem; color: var(--gray-500); margin-top: 16px; display: flex; align-items: center; gap: 12px; }
.stat-card { background: var(--white); border-radius: var(--radius-md); padding: 28px 24px; text-align: center; box-shadow: var(--shadow-sm); border-top: 4px solid var(--green-500); transition: all var(--transition); }
.stat-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-top-color: var(--gold); }
.stat-icon { font-size: 2.5rem; margin-bottom: 12px; }
.stat-number { font-family: 'Playfair Display', serif; font-size: 2.2rem; font-weight: 700; color: var(--green-800); }
.stat-label { font-size: 0.85rem; color: var(--gray-500); font-weight: 500; }
.achievement-badge { width: 80px; height: 80px; border-radius: 50%; margin: 0 auto 16px; display: flex; align-items: center; justify-content: center; font-size: 2rem; }
.badge-gold { background: linear-gradient(135deg, #F9A825, #FFD54F); }
.badge-silver { background: linear-gradient(135deg, #78909C, #B0BEC5); }
.badge-bronze { background: linear-gradient(135deg, #8D6E63, #BCAAA4); }
.badge-blue { background: linear-gradient(135deg, #1565C0, #42A5F5); }

/* ---- NEWS TICKER ---- */
.news-ticker { background: var(--green-900); color: var(--white); padding: 10px 0; overflow: hidden; display: flex; align-items: center; }
.ticker-label { background: var(--gold); color: var(--green-900); padding: 2px 16px; font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; white-space: nowrap; flex-shrink: 0; margin-right: 20px; }
.ticker-track { display: flex; animation: ticker 30s linear infinite; }
.ticker-track span { white-space: nowrap; padding-right: 60px; font-size: 0.875rem; }

/* ---- FOOTER ---- */
.footer { background: var(--green-900); color: rgba(255,255,255,0.8); padding: 60px 5% 30px; }
.footer-grid { display: grid; grid-template-columns: 2fr repeat(3, 1fr); gap: 40px; margin-bottom: 40px; }
.footer-brand img { height: 60px; width: 60px; border-radius: 50%; border: 2px solid var(--gold); margin-bottom: 16px; }
.footer-brand h3 { font-family: 'Playfair Display', serif; color: var(--white); margin-bottom: 8px; }
.footer h4 { font-family: 'Inter', sans-serif; font-size: 0.75rem; font-weight: 700; letter-spacing: 2px; text-transform: uppercase; color: var(--gold); margin-bottom: 16px; }
.footer ul li a { color: rgba(255,255,255,0.7); font-size: 0.875rem; transition: all var(--transition); display: block; padding: 4px 0; }
.footer ul li a:hover { color: var(--gold); padding-left: 4px; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.1); padding-top: 24px; display: flex; justify-content: space-between; align-items: center; font-size: 0.8rem; flex-wrap: wrap; gap: 12px; }
.social-links { display: flex; gap: 12px; }
.social-links a { width: 36px; height: 36px; border-radius: 50%; background: rgba(255,255,255,0.1); display: flex; align-items: center; justify-content: center; color: var(--white); font-size: 1rem; transition: all var(--transition); }
.social-links a:hover { background: var(--gold); color: var(--green-900); transform: translateY(-2px); }

/* ---- FLASH ---- */
.flash { padding: 14px 20px; border-radius: var(--radius-sm); margin: 12px 0; font-size: 0.9rem; font-weight: 500; display: flex; align-items: center; gap: 10px; animation: slideIn 0.3s ease; }
.flash-success { background: #E8F5E9; color: #2E7D32; border-left: 4px solid #4CAF50; }
.flash-error { background: var(--danger-light); color: var(--danger); border-left: 4px solid var(--danger); }
.flash-warning { background: #FFF8E1; color: #E65100; border-left: 4px solid var(--gold); }
.flash-info { background: #E3F2FD; color: #01579B; border-left: 4px solid #2196F3; }

/* ---- PAGE HERO ---- */
.page-hero { background: linear-gradient(135deg, var(--green-900), var(--green-700)); padding: 120px 5% 60px; text-align: center; }
.page-hero h1 { color: var(--white); margin-bottom: 12px; }
.page-hero p { color: rgba(255,255,255,0.8); font-size: 1.05rem; }
.breadcrumb { display: flex; gap: 8px; align-items: center; justify-content: center; margin-top: 16px; font-size: 0.8rem; }
.breadcrumb a { color: var(--gold); }
.breadcrumb span { color: rgba(255,255,255,0.5); }

/* ---- FORMS ---- */
.form-group { margin-bottom: 20px; }
.form-group label { display: block; font-size: 0.85rem; font-weight: 600; color: var(--gray-700); margin-bottom: 6px; }
.form-control { width: 100%; padding: 12px 16px; border: 2px solid var(--gray-200); border-radius: var(--radius-sm); font-size: 0.9rem; font-family: 'Inter', sans-serif; color: var(--gray-900); transition: all var(--transition); background: var(--white); }
.form-control:focus { outline: none; border-color: var(--green-500); box-shadow: 0 0 0 3px rgba(76,175,80,0.15); }
textarea.form-control { resize: vertical; min-height: 120px; }
select.form-control { cursor: pointer; }

/* ---- TABLES ---- */
.table-wrapper { overflow-x: auto; border-radius: var(--radius-md); box-shadow: var(--shadow-sm); }
table { width: 100%; border-collapse: collapse; background: var(--white); }
thead th { background: var(--green-800); color: var(--white); padding: 14px 16px; font-size: 0.85rem; font-weight: 600; text-align: left; }
tbody td { padding: 12px 16px; font-size: 0.875rem; border-bottom: 1px solid var(--gray-200); }
tbody tr:hover { background: var(--green-50); }
tbody tr:last-child td { border-bottom: none; }
.grade-badge { display: inline-block; padding: 2px 10px; border-radius: 50px; font-size: 0.75rem; font-weight: 700; }
.grade-A { background: #E8F5E9; color: #1B5E20; }
.grade-B { background: #E3F2FD; color: #0D47A1; }
.grade-C { background: #FFF8E1; color: #E65100; }
.grade-S { background: #F3E5F5; color: #4A148C; }
.grade-W { background: var(--danger-light); color: var(--danger); }

/* ---- LOGIN ---- */
.login-page { min-height: 100vh; background: linear-gradient(135deg, var(--green-900) 0%, var(--green-700) 60%, var(--green-500) 100%); display: flex; align-items: center; justify-content: center; padding: 20px; }
.login-card { background: rgba(255,255,255,0.98); border-radius: var(--radius-xl); padding: 48px 44px; width: 100%; max-width: 440px; box-shadow: 0 24px 80px rgba(0,0,0,0.3); animation: fadeInUp 0.6s ease; }
.login-logo { text-align: center; margin-bottom: 32px; }
.login-logo img { width: 80px; height: 80px; border-radius: 50%; border: 4px solid var(--green-100); margin: 0 auto 12px; }
.login-logo h2 { font-size: 1.4rem; color: var(--green-900); }
.login-logo p { font-size: 0.8rem; color: var(--gray-500); }
.login-tabs { display: flex; background: var(--gray-100); border-radius: var(--radius-sm); padding: 4px; margin-bottom: 28px; gap: 4px; flex-wrap: wrap; }
.login-tab { flex: 1; text-align: center; padding: 8px 6px; font-size: 0.72rem; font-weight: 600; border-radius: 6px; cursor: pointer; transition: all var(--transition); color: var(--gray-500); min-width: fit-content; }
.login-tab.active { background: var(--green-700); color: var(--white); box-shadow: 0 2px 8px rgba(56,142,60,0.3); }

/* ---- FEATURE CARD ---- */
.feature-icon { width: 64px; height: 64px; border-radius: var(--radius-md); background: linear-gradient(135deg, var(--green-600), var(--green-800)); display: flex; align-items: center; justify-content: center; font-size: 1.8rem; margin-bottom: 20px; box-shadow: 0 4px 16px rgba(56,142,60,0.3); }
.feature-card { padding: 32px 28px; }
.feature-card h3 { font-size: 1.2rem; margin-bottom: 10px; }

/* ---- STATUS BADGES ---- */
.badge { display: inline-block; padding: 3px 12px; border-radius: 50px; font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; }
.badge-success { background: #E8F5E9; color: #2E7D32; }
.badge-warning { background: #FFF8E1; color: #E65100; }
.badge-danger  { background: var(--danger-light); color: var(--danger); }
.badge-info    { background: #E3F2FD; color: #01579B; }
.badge-gold    { background: #FFF8E1; color: #E65100; border: 1px solid var(--gold); }

/* ---- ANIMATIONS ---- */
@keyframes fadeInUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeInDown { from { opacity: 0; transform: translateY(-20px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideIn { from { opacity: 0; transform: translateX(-10px); } to { opacity: 1; transform: translateX(0); } }
@keyframes ticker { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }
@keyframes bounce { 0%,100% { transform: translateX(-50%) translateY(0); } 50% { transform: translateX(-50%) translateY(-8px); } }
.reveal { opacity: 0; transform: translateY(30px); transition: all 0.7s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ---- RESPONSIVE ---- */
@media (max-width: 768px) {
  .nav-links { display: none; flex-direction: column; position: fixed; top: 70px; left: 0; right: 0; background: var(--green-900); padding: 20px; gap: 4px; }
  .nav-links.open { display: flex; }
  .nav-toggle { display: flex; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .login-card { padding: 32px 24px; }
}
@media (max-width: 480px) {
  .footer-grid { grid-template-columns: 1fr; }
  .hero-buttons { flex-direction: column; align-items: center; }
  .hero-stats { gap: 24px; }
}
