/* -------------------------------------------------------------
 * SCHOOL DIGITAL STUDENT PORTFOLIO PLATFORM
 * Modern, Responsive, Accessible Stylesheet
 * ------------------------------------------------------------- */

:root {
  --primary: #4338ca;
  --primary-hover: #3730a3;
  --primary-light: #eef2ff;
  --primary-gradient: linear-gradient(135deg, #4f46e5 0%, #3b82f6 50%, #06b6d4 100%);
  --accent-gradient: linear-gradient(135deg, #f59e0b 0%, #ef4444 100%);
  --success: #10b981;
  --success-bg: #ecfdf5;
  --warning: #f59e0b;
  --danger: #ef4444;
  --info: #0284c7;
  
  --bg-main: #f8fafc;
  --bg-surface: #ffffff;
  --bg-subtle: #f1f5f9;
  --border: #e2e8f0;
  --border-focus: #818cf8;
  
  --text-main: #0f172a;
  --text-muted: #64748b;
  --text-light: #94a3b8;
  --text-inverse: #ffffff;

  --font-sans: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --radius-full: 9999px;
  
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md: 0 4px 12px -2px rgba(15,23,42,0.08), 0 2px 6px -1px rgba(15,23,42,0.04);
  --shadow-lg: 0 12px 28px -4px rgba(15,23,42,0.12), 0 4px 10px -2px rgba(15,23,42,0.06);
  --shadow-xl: 0 20px 35px -8px rgba(15,23,42,0.18);
  
  --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-col;
  flex-direction: column;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  color: var(--text-main);
  font-weight: 700;
  line-height: 1.25;
}

p {
  color: var(--text-muted);
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: var(--transition);
}

a:hover {
  color: var(--primary-hover);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Container */
.container {
  width: 100%;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: 1.5rem;
}

.container-narrow {
  max-width: 900px;
}

/* Navigation Bar */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  padding: 0.85rem 0;
  transition: var(--transition);
}

.nav-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  text-decoration: none;
}

.brand-logo {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  object-fit: cover;
  box-shadow: var(--shadow-sm);
  border: 2px solid var(--border);
}

.brand-text h1 {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.02em;
}

.brand-text p {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 500;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  list-style: none;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 0.9rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.nav-link:hover, .nav-link.active {
  color: var(--primary);
  background: var(--primary-light);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.65rem 1.25rem;
  font-size: 0.92rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 4px 14px rgba(79, 70, 229, 0.35);
}

.btn-primary:hover {
  background: var(--primary-hover);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(79, 70, 229, 0.45);
}

.btn-secondary {
  background: var(--bg-surface);
  color: var(--text-main);
  border-color: var(--border);
  box-shadow: var(--shadow-sm);
}

.btn-secondary:hover {
  background: var(--bg-subtle);
  border-color: var(--text-light);
  color: var(--text-main);
}

.btn-accent {
  background: var(--primary-gradient);
  color: #fff;
  font-weight: 700;
}

.btn-accent:hover {
  opacity: 0.95;
  transform: translateY(-1px);
  color: #fff;
}

.btn-sm {
  padding: 0.4rem 0.75rem;
  font-size: 0.82rem;
  border-radius: var(--radius-sm);
}

.btn-icon {
  padding: 0.55rem;
  border-radius: var(--radius-full);
}

/* Badges & Chips */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.65rem;
  font-size: 0.78rem;
  font-weight: 700;
  border-radius: var(--radius-full);
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.badge-primary { background: var(--primary-light); color: var(--primary); }
.badge-success { background: var(--success-bg); color: var(--success); }
.badge-warning { background: #fef3c7; color: #b45309; }
.badge-info { background: #e0f2fe; color: var(--info); }
.badge-dark { background: #1e293b; color: #f8fafc; }

/* Cards & Panels */
.card {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  padding: 1.75rem;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.card:hover {
  box-shadow: var(--shadow-md);
  border-color: #cbd5e1;
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border);
}

.card-title {
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Section Header */
.section-header {
  text-align: center;
  max-width: 650px;
  margin: 0 auto 2.5rem;
}

.section-header .tag {
  color: var(--primary);
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.5rem;
  display: block;
}

.section-header h2 {
  font-size: 2rem;
  letter-spacing: -0.03em;
  margin-bottom: 0.5rem;
}

/* =============================================================
   HUB / DIRECTORY (index.html)
   ============================================================= */
.hero-hub {
  background: var(--primary-gradient);
  color: #fff;
  padding: 4.5rem 0 3.5rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero-hub::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top right, rgba(255,255,255,0.18), transparent 60%);
  pointer-events: none;
}

.hero-hub h1 {
  font-size: 2.75rem;
  color: #fff;
  font-weight: 800;
  letter-spacing: -0.04em;
  margin-bottom: 0.75rem;
}

.hero-hub p {
  color: rgba(255, 255, 255, 0.9);
  font-size: 1.2rem;
  max-width: 700px;
  margin: 0 auto 2rem;
}

.search-filter-bar {
  background: #fff;
  border-radius: var(--radius-xl);
  padding: 0.65rem 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  box-shadow: var(--shadow-xl);
  max-width: 780px;
  margin: 0 auto;
  border: 1px solid rgba(255,255,255,0.4);
}

.search-input-wrap {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding-left: 0.5rem;
}

.search-input-wrap input {
  width: 100%;
  border: none;
  outline: none;
  font-size: 1rem;
  color: var(--text-main);
  background: transparent;
}

.filter-select {
  border: 1px solid var(--border);
  background: var(--bg-subtle);
  padding: 0.55rem 1rem;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--text-main);
  outline: none;
  cursor: pointer;
}

/* Student Cards Grid */
.students-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.75rem;
  margin: 3rem 0;
}

.student-card {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.student-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--border-focus);
}

.card-banner {
  height: 90px;
  background: var(--primary-gradient);
  position: relative;
}

.card-avatar-wrapper {
  position: relative;
  margin-top: -45px;
  padding: 0 1.5rem;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
}

.student-card-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  border: 4px solid #fff;
  box-shadow: var(--shadow-md);
  object-fit: cover;
  background: #cbd5e1;
}

.student-card-body {
  padding: 1rem 1.5rem 1.5rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.student-card-name {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.2rem;
  color: var(--text-main);
}

.student-card-meta {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 0.65rem;
}

.student-card-bio {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.student-card-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
  background: var(--bg-subtle);
  padding: 0.65rem;
  border-radius: var(--radius-md);
  margin-bottom: 1.25rem;
  text-align: center;
}

.stat-num {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--text-main);
}

.stat-lbl {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-transform: uppercase;
  font-weight: 600;
}

.student-card-actions {
  margin-top: auto;
  display: flex;
  gap: 0.5rem;
}

/* =============================================================
   STUDENT PORTFOLIO (portfolio.html)
   ============================================================= */
.portfolio-hero {
  position: relative;
  background: #0f172a;
  color: #fff;
  padding-bottom: 3.5rem;
  overflow: hidden;
}

.portfolio-cover {
  height: 240px;
  width: 100%;
  object-fit: cover;
  opacity: 0.45;
  filter: blur(1px);
}

.portfolio-hero-content {
  position: relative;
  margin-top: -100px;
}

.hero-profile-box {
  background: rgba(255, 255, 255, 0.98);
  border-radius: var(--radius-xl);
  padding: 2.25rem;
  box-shadow: var(--shadow-xl);
  border: 1px solid var(--border);
  color: var(--text-main);
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 2rem;
  align-items: center;
}

.hero-avatar {
  width: 140px;
  height: 140px;
  border-radius: var(--radius-lg);
  object-fit: cover;
  box-shadow: var(--shadow-md);
  border: 4px solid #fff;
}

.hero-info h1 {
  font-size: 2.1rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 0.25rem;
}

.hero-class-tag {
  font-size: 1rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 0.5rem;
}

.hero-tagline {
  font-size: 1.05rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.hero-motto {
  font-style: italic;
  font-weight: 600;
  color: var(--info);
  font-size: 0.92rem;
}

.hero-badges-side {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.75rem;
}

.qr-trigger-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  padding: 0.5rem 0.9rem;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-main);
  cursor: pointer;
  transition: var(--transition);
}

.qr-trigger-btn:hover {
  background: var(--primary-light);
  color: var(--primary);
  border-color: var(--border-focus);
}

/* Portfolio Navigation Sticky Bar */
.portfolio-nav-bar {
  background: #fff;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 72px;
  z-index: 90;
  padding: 0.5rem 0;
  box-shadow: 0 2px 8px rgba(0,0,0,0.03);
}

.portfolio-nav-links {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  scrollbar-width: none;
  padding-inline: 0.25rem;
}

.portfolio-nav-links::-webkit-scrollbar {
  display: none;
}

.p-nav-btn {
  padding: 0.45rem 0.9rem;
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-muted);
  white-space: nowrap;
  transition: var(--transition);
}

.p-nav-btn:hover, .p-nav-btn.active {
  background: var(--primary);
  color: #fff;
}

/* Section styling */
.portfolio-section {
  padding: 3.5rem 0;
  border-bottom: 1px solid var(--border);
}

/* Video Showcase */
.video-showcase-card {
  background: #0f172a;
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-xl);
  color: #fff;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
}

.video-frame-wrap {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  background: #000;
}

.video-frame-wrap iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.video-details {
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.video-details h3 {
  color: #fff;
  font-size: 1.6rem;
  margin-bottom: 0.85rem;
}

.video-details p {
  color: #94a3b8;
  font-size: 1rem;
  margin-bottom: 1.5rem;
}

/* Growth Records: Before -> After */
.growth-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.5rem;
}

.growth-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.growth-skill-title {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-main);
}

.before-after-container {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  position: relative;
}

.state-box {
  padding: 0.85rem 1rem;
  border-radius: var(--radius-md);
  font-size: 0.88rem;
  line-height: 1.45;
}

.state-before {
  background: #fff1f2;
  border-left: 4px solid #f43f5e;
  color: #881337;
}

.state-after {
  background: #ecfdf5;
  border-left: 4px solid #10b981;
  color: #064e3b;
  font-weight: 500;
}

.state-arrow {
  text-align: center;
  font-size: 1.1rem;
  color: var(--primary);
  font-weight: 900;
}

/* Scorecard & Competency Matrix */
.scorecard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
}

.scorecard-item {
  background: var(--bg-surface);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

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

.score-name {
  font-weight: 700;
  font-size: 0.98rem;
  color: var(--text-main);
}

.score-stars {
  color: #f59e0b;
  font-size: 1.1rem;
  letter-spacing: 2px;
}

.score-bar-bg {
  width: 100%;
  height: 8px;
  background: var(--bg-subtle);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.score-bar-fill {
  height: 100%;
  background: var(--primary-gradient);
  border-radius: var(--radius-full);
}

.score-desc {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Projects Showcase */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 2rem;
}

.project-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  transition: var(--transition);
}

.project-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--border-focus);
}

.project-thumb-wrap {
  position: relative;
  height: 190px;
  overflow: hidden;
  background: #1e293b;
}

.project-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.project-card:hover .project-thumb {
  transform: scale(1.05);
}

.project-category-chip {
  position: absolute;
  top: 1rem;
  left: 1rem;
  background: rgba(15, 23, 42, 0.8);
  backdrop-filter: blur(8px);
  color: #fff;
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 700;
}

.project-body {
  padding: 1.5rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.project-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.project-summary {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
  flex: 1;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1.25rem;
}

.tech-tag {
  background: var(--bg-subtle);
  color: var(--text-main);
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  font-weight: 600;
}

.project-impact {
  background: #fdf4ff;
  border-left: 3px solid #c084fc;
  padding: 0.5rem 0.75rem;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 0.8rem;
  color: #6b21a8;
  font-weight: 600;
  margin-bottom: 1.25rem;
}

.project-footer {
  display: flex;
  gap: 0.5rem;
  margin-top: auto;
}

/* Achievements & Badges */
.achievements-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.5rem;
}

.achievement-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.achievement-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: #f59e0b;
}

.achievement-badge-icon {
  font-size: 2.25rem;
  flex-shrink: 0;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: #fef3c7;
  display: flex;
  align-items: center;
  justify-content: center;
}

.achievement-info h4 {
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 0.2rem;
}

.achievement-info p {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Gallery Lightbox */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.25rem;
}

.gallery-item {
  position: relative;
  height: 200px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  cursor: pointer;
}

.gallery-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.gallery-item:hover .gallery-img {
  transform: scale(1.08);
}

.gallery-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(15,23,42,0.85) 0%, transparent 70%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1rem;
  color: #fff;
  opacity: 0.9;
}

.gallery-title {
  font-size: 0.85rem;
  font-weight: 700;
}

.gallery-tag {
  font-size: 0.7rem;
  color: #38bdf8;
  font-weight: 600;
}

/* Observations & Remarks */
.observations-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

.observation-box {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  position: relative;
}

.quote-icon {
  font-size: 2.5rem;
  color: var(--primary);
  opacity: 0.2;
  position: absolute;
  top: 1.25rem;
  right: 1.5rem;
}

.observation-text {
  font-size: 1rem;
  color: var(--text-main);
  line-height: 1.7;
  font-style: italic;
  margin-bottom: 1.5rem;
}

.person-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.person-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
}

.person-details h5 {
  font-size: 0.95rem;
  font-weight: 700;
}

.person-details p {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Future Goals */
.goals-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
}

.goal-item {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-left: 4px solid var(--primary);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  padding: 1.25rem;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-main);
  display: flex;
  gap: 0.75rem;
}

/* =============================================================
   ADMIN PANEL (admin.html)
   ============================================================= */
.admin-layout {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 2rem;
  margin: 2.5rem 0 4rem;
}

.admin-sidebar {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  height: fit-content;
}

.admin-student-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-top: 1rem;
  max-height: 500px;
  overflow-y: auto;
}

.admin-student-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  cursor: pointer;
  transition: var(--transition);
}

.admin-student-item:hover {
  background: var(--bg-subtle);
}

.admin-student-item.active {
  background: var(--primary-light);
  border-color: var(--border-focus);
}

.admin-student-thumb {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
}

.admin-form-container {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 2.5rem;
  box-shadow: var(--shadow-sm);
}

.form-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}

.form-grid-3 {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 1.25rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 1.25rem;
}

.form-group label {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-main);
}

.form-control {
  width: 100%;
  padding: 0.65rem 0.9rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  font-size: 0.92rem;
  font-family: inherit;
  color: var(--text-main);
  background: var(--bg-surface);
  transition: var(--transition);
  outline: none;
}

.form-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.15);
}

textarea.form-control {
  min-height: 90px;
  resize: vertical;
}

.form-section-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-main);
  margin: 2rem 0 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--bg-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Dynamic Rows in Admin (Projects, Growth, Goals) */
.dynamic-row {
  background: var(--bg-subtle);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  margin-bottom: 1rem;
  position: relative;
  border: 1px solid var(--border);
}

.remove-row-btn {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  background: #fee2e2;
  color: #ef4444;
  border: none;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-weight: 800;
  transition: var(--transition);
}

.remove-row-btn:hover {
  background: #ef4444;
  color: #fff;
}

/* =============================================================
   ID CARD & QR SYSTEM (id-card.html)
   ============================================================= */
.id-cards-container {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: center;
  margin: 3rem 0 4rem;
}

.id-card {
  width: 340px;
  height: 520px;
  background: #fff;
  border-radius: 20px;
  border: 1px solid #cbd5e1;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  position: relative;
  page-break-inside: avoid;
}

.id-header {
  background: var(--primary-gradient);
  color: #fff;
  padding: 1.25rem 1rem;
  text-align: center;
}

.id-header h3 {
  color: #fff;
  font-size: 1rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.id-header p {
  color: rgba(255,255,255,0.85);
  font-size: 0.7rem;
  font-weight: 600;
}

.id-body {
  padding: 1.25rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.id-avatar {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  border: 4px solid var(--primary-light);
  object-fit: cover;
  box-shadow: var(--shadow-sm);
  margin-top: -5px;
  margin-bottom: 0.75rem;
}

.id-student-name {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--text-main);
}

.id-student-class {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 0.75rem;
}

.id-qr-box {
  background: #fff;
  padding: 0.5rem;
  border: 2px dashed #cbd5e1;
  border-radius: var(--radius-md);
  margin-bottom: 0.6rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.id-qr-box canvas {
  width: 125px !important;
  height: 125px !important;
}

.id-scan-hint {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.id-footer {
  background: var(--bg-subtle);
  border-top: 1px solid var(--border);
  padding: 0.65rem 1rem;
  font-size: 0.68rem;
  color: var(--text-muted);
  text-align: center;
  font-weight: 600;
}

/* =============================================================
   MODALS (QR Popup, Lightbox)
   ============================================================= */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(6px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  pointer-events: none;
  transition: var(--transition);
}

.modal-backdrop.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-card {
  background: #fff;
  border-radius: var(--radius-xl);
  padding: 2.25rem;
  max-width: 480px;
  width: 100%;
  box-shadow: var(--shadow-xl);
  text-align: center;
  transform: scale(0.92);
  transition: var(--transition);
}

.modal-backdrop.active .modal-card {
  transform: scale(1);
}

/* Footer */
.footer {
  background: #0f172a;
  color: #94a3b8;
  padding: 3rem 0 2rem;
  margin-top: auto;
  border-top: 1px solid #1e293b;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.footer-brand h4 {
  color: #fff;
  font-size: 1.1rem;
}

.footer-brand p {
  color: #64748b;
  font-size: 0.85rem;
}

/* Media Queries & Responsiveness */
@media (max-width: 900px) {
  .hero-profile-box {
    grid-template-columns: 1fr;
    text-align: center;
    justify-items: center;
  }
  .hero-badges-side {
    align-items: center;
  }
  .video-showcase-card {
    grid-template-columns: 1fr;
  }
  .observations-grid {
    grid-template-columns: 1fr;
  }
  .admin-layout {
    grid-template-columns: 1fr;
  }
  .form-grid-2, .form-grid-3 {
    grid-template-columns: 1fr;
  }
}

/* Print Stylesheet */
@media print {
  body {
    background: #fff !important;
    color: #000 !important;
  }
  .navbar, .footer, .portfolio-nav-bar, .qr-trigger-btn, .btn, .no-print {
    display: none !important;
  }
  .id-cards-container {
    display: block !important;
  }
  .id-card {
    box-shadow: none !important;
    border: 1px solid #000 !important;
    margin: 0 auto 2rem !important;
  }
  .portfolio-hero-content {
    margin-top: 0 !important;
  }
  .card, .hero-profile-box {
    box-shadow: none !important;
    border: 1px solid #ddd !important;
  }
}


/* =============================================================
   3 TECHNOLOGY TEAMS (IT, ROBOTICS, AI) & ACTIVITY CYCLE STYLES
   ============================================================= */

/* Team Colors & Gradients */
:root {
  --it-primary: #4f46e5;
  --it-gradient: linear-gradient(135deg, #4f46e5 0%, #06b6d4 100%);
  --it-light: #eef2ff;
  --it-border: #c7d2fe;

  --robotics-primary: #059669;
  --robotics-gradient: linear-gradient(135deg, #059669 0%, #0d9488 100%);
  --robotics-light: #ecfdf5;
  --robotics-border: #a7f3d0;

  --ai-primary: #7c3aed;
  --ai-gradient: linear-gradient(135deg, #7c3aed 0%, #ec4899 100%);
  --ai-light: #f5f3ff;
  --ai-border: #ddd6fe;
}

/* Team Badges */
.team-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-full);
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

.team-badge-it {
  background: #e0e7ff;
  color: #3730a3;
  border: 1px solid #c7d2fe;
}

.team-badge-robotics {
  background: #d1fae5;
  color: #065f46;
  border: 1px solid #a7f3d0;
}

.team-badge-ai {
  background: #ede9fe;
  color: #5b21b6;
  border: 1px solid #ddd6fe;
}

/* Team Filter Tabs */
.team-filter-tabs {
  display: flex;
  justify-content: center;
  gap: 0.65rem;
  margin-top: 1.5rem;
  flex-wrap: wrap;
}

.team-tab {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.35);
  padding: 0.5rem 1.15rem;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 0.9rem;
  cursor: pointer;
  backdrop-filter: blur(8px);
  transition: var(--transition);
}

.team-tab:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: translateY(-1px);
}

.team-tab.active {
  background: #fff;
  color: var(--text-main);
  box-shadow: var(--shadow-md);
  border-color: #fff;
}

/* Team Banners & Card Borders */
.team-banner-it { background: var(--it-gradient) !important; }
.team-banner-robotics { background: var(--robotics-gradient) !important; }
.team-banner-ai { background: var(--ai-gradient) !important; }

.team-border-it:hover { border-color: var(--it-primary) !important; }
.team-border-robotics:hover { border-color: var(--robotics-primary) !important; }
.team-border-ai:hover { border-color: var(--ai-primary) !important; }

.student-card-featured-project {
  background: var(--bg-subtle);
  border-left: 3px solid var(--primary);
  padding: 0.5rem 0.75rem;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin-bottom: 1rem;
}

/* Activity Cycle Banner (index.html) */
.activity-cycle-banner {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 1.75rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: var(--shadow-md);
  flex-wrap: wrap;
  gap: 1.5rem;
  position: relative;
  overflow: hidden;
}

.activity-cycle-banner::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 6px;
  background: var(--primary-gradient);
}

.ac-banner-left {
  max-width: 420px;
}

.ac-banner-left h3 {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 0.35rem;
}

.ac-banner-left p {
  font-size: 0.88rem;
  line-height: 1.45;
}

.ac-banner-steps {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.ac-step-pill {
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  padding: 0.45rem 0.85rem;
  border-radius: var(--radius-md);
  font-size: 0.82rem;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  color: var(--text-main);
}

.ac-step-arrow {
  color: var(--primary);
  font-weight: 900;
  font-size: 1rem;
}

/* Activity Cycle Stepper (teams.html) */
.activity-cycle-stepper {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr auto 1fr;
  gap: 0.75rem;
  align-items: center;
  margin-top: 2rem;
}

@media (max-width: 900px) {
  .activity-cycle-stepper {
    grid-template-columns: 1fr;
  }
  .cycle-connector {
    display: none;
  }
}

.cycle-step-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem 1.5rem;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  height: 100%;
  position: relative;
  transition: var(--transition);
}

.cycle-step-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary);
}

.cycle-step-num {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--primary-light);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.85rem;
}

.cycle-icon {
  font-size: 2.25rem;
  margin-bottom: 0.75rem;
}

.cycle-step-card h3 {
  font-size: 1.25rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
}

.cycle-step-card p {
  font-size: 0.88rem;
  line-height: 1.5;
  margin-bottom: 1rem;
  flex: 1;
}

.cycle-example {
  background: var(--bg-subtle);
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-sm);
  font-size: 0.78rem;
  color: var(--text-main);
  border-left: 3px solid var(--primary);
}

.cycle-connector {
  font-size: 1.5rem;
  color: var(--primary);
  font-weight: 900;
  text-align: center;
}

/* Teams In-Depth Overview (teams.html) */
.team-overview-section {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 2.5rem;
  box-shadow: var(--shadow-md);
  position: relative;
}

.it-theme { border-top: 5px solid var(--it-primary); }
.robotics-theme { border-top: 5px solid var(--robotics-primary); }
.ai-theme { border-top: 5px solid var(--ai-primary); }

.team-section-header {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
}

.team-badge-icon {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  flex-shrink: 0;
}

.team-output-pill {
  background: #eef2ff;
  border: 1px solid #c7d2fe;
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-lg);
  font-size: 0.88rem;
  color: #312e81;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.team-details-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 2rem;
}

@media (max-width: 850px) {
  .team-details-grid {
    grid-template-columns: 1fr;
  }
}

.team-tasks-card {
  background: var(--bg-subtle);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  border: 1px solid var(--border);
}

.team-task-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.team-task-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  font-size: 0.92rem;
  color: var(--text-main);
}

.team-roster-card {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  border: 1px solid var(--border);
}

.team-student-chips {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.team-student-item {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.75rem;
  background: var(--bg-subtle);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  transition: var(--transition);
}

.team-student-item:hover {
  background: #fff;
  box-shadow: var(--shadow-sm);
  border-color: var(--primary);
}

.team-student-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
}

/* Activity Cycle Project Card (portfolio.html) */
.activity-cycle-project-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 2.25rem;
  box-shadow: var(--shadow-md);
  margin-top: 1rem;
}

.cycle-timeline-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.25rem;
  position: relative;
}

.timeline-step {
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: var(--transition);
}

.timeline-step:hover {
  background: #fff;
  box-shadow: var(--shadow-md);
  border-color: var(--primary);
}

.step-badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  color: var(--primary);
  background: var(--primary-light);
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-full);
  margin-bottom: 0.75rem;
  align-self: flex-start;
}

.step-title {
  font-size: 1.05rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
  color: var(--text-main);
}

.step-desc {
  font-size: 0.85rem;
  line-height: 1.5;
  color: var(--text-muted);
}

/* Deliverables Verification Checklist (portfolio.html) */
.deliverables-box {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
}

.deliverables-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
  gap: 1rem;
}

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

.checklist-item {
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.85rem 1.15rem;
  display: flex;
  align-items: center;
  gap: 0.85rem;
  transition: var(--transition);
}

.checklist-item.verified {
  background: #ecfdf5;
  border-color: #a7f3d0;
}

.checklist-icon {
  font-size: 1.35rem;
  flex-shrink: 0;
}



/* =============================================================
   COMPREHENSIVE SCREEN FIT & MOBILE/TABLET/DESKTOP RESPONSIVENESS
   ============================================================= */

/* Universal fluid viewport fit */
html, body {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  box-sizing: border-box;
}

*, *::before, *::after {
  box-sizing: inherit;
}

/* Fluid Typography */
h1 { font-size: clamp(1.6rem, 4vw + 0.5rem, 2.5rem); }
h2 { font-size: clamp(1.35rem, 3vw + 0.5rem, 2rem); }
h3 { font-size: clamp(1.15rem, 2.5vw + 0.3rem, 1.5rem); }

.container {
  width: 100%;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: clamp(1rem, 3.5vw, 2rem);
}

/* Navbar mobile fit */
@media (max-width: 640px) {
  .navbar {
    padding: 0.5rem 0;
  }
  .nav-wrapper {
    flex-direction: column;
    gap: 0.6rem;
    align-items: stretch;
  }
  .brand {
    justify-content: center;
    text-align: center;
  }
  .brand-text h1 {
    font-size: 1rem;
  }
  .brand-text p {
    font-size: 0.7rem;
  }
  .nav-links {
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.35rem;
    width: 100%;
  }
  .nav-link {
    font-size: 0.78rem;
    padding: 0.35rem 0.6rem;
  }
  .btn-sm {
    font-size: 0.75rem;
    padding: 0.35rem 0.6rem;
  }
}

/* Hub search filter responsive */
@media (max-width: 640px) {
  .hero-hub {
    padding: 2.5rem 0 2rem;
  }
  .hero-hub h1 {
    font-size: 1.75rem;
  }
  .hero-hub p {
    font-size: 0.95rem;
    padding-inline: 0.5rem;
  }
  .search-filter-bar {
    flex-direction: column;
    padding: 0.5rem;
    border-radius: var(--radius-lg);
    gap: 0.5rem;
  }
  .search-input-wrap {
    width: 100%;
    padding: 0.35rem;
  }
  .filter-select {
    width: 100%;
  }
  .team-filter-tabs {
    gap: 0.35rem;
  }
  .team-tab {
    font-size: 0.78rem;
    padding: 0.35rem 0.75rem;
  }
}

/* Student card grid responsive */
.students-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr));
  gap: clamp(1rem, 2.5vw, 1.75rem);
}

/* Activity Cycle Banner responsive */
@media (max-width: 768px) {
  .activity-cycle-banner {
    flex-direction: column;
    align-items: flex-start;
    padding: 1.25rem;
  }
  .ac-banner-steps {
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
    gap: 0.35rem;
  }
  .ac-step-arrow {
    transform: rotate(90deg);
    align-self: center;
  }
  .ac-step-pill {
    width: 100%;
    justify-content: flex-start;
  }
}

/* Student Portfolio Hero Responsive */
@media (max-width: 900px) {
  .portfolio-hero {
    padding-bottom: 2rem;
  }
  .portfolio-cover {
    height: 160px;
  }
  .portfolio-hero-content {
    margin-top: -60px;
  }
  .hero-profile-box {
    grid-template-columns: 1fr;
    text-align: center;
    padding: 1.5rem 1rem;
    gap: 1.25rem;
  }
  .hero-avatar {
    width: 110px;
    height: 110px;
    margin-inline: auto;
  }
  .hero-badges-side {
    width: 100%;
    align-items: center;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
  }
}

/* Sticky in-page nav */
.portfolio-nav-bar {
  top: 0;
}

@media (max-width: 640px) {
  .portfolio-nav-links {
    gap: 0.3rem;
  }
  .p-nav-btn {
    font-size: 0.75rem;
    padding: 0.35rem 0.65rem;
  }
}

/* Projects grid responsive */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr));
  gap: clamp(1rem, 2.5vw, 1.75rem);
}

/* ID Card Responsive */
.id-card {
  max-width: 100%;
  width: min(340px, 92vw);
}

@media (max-width: 480px) {
  .id-cards-container {
    gap: 1rem;
  }
  .id-card {
    height: auto;
    min-height: 480px;
  }
}

/* Deliverables & Checklist Grid */
.checklist-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  gap: 0.75rem;
}

/* Modal responsive */
.modal-card {
  max-width: min(480px, 94vw);
  padding: clamp(1.25rem, 4vw, 2.25rem);
}

