/* JharForm Student Hub - Shared Styles */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
  --primary: #3B48E0;
  --primary-hover: #2D3AB0;
  --primary-light: rgba(59, 72, 224, 0.10);
  --bg: #F8F9FF;
  --white: #FFFFFF;
  --text: #1a1a2e;
  --text-secondary: #6B7280;
  --border: #E5E7EB;
  --success: #10B981;
  --warning: #F59E0B;
  --danger: #EF4444;
  --radius: 12px;
  --shadow: 0 2px 16px rgba(59, 72, 224, 0.08);
  --shadow-hover: 0 6px 28px rgba(59, 72, 224, 0.18);
}

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 16px;
}

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

/* ===== NAVBAR ===== */
.nav {
  background: #fff;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 1px 8px rgba(0,0,0,0.06);
}
.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
  gap: 1rem;
}
.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--primary);
  flex-shrink: 0;
}
.logo-icon {
  width: 32px;
  height: 32px;
  background: var(--primary);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 0.75rem;
  font-weight: 800;
}
.nav-links {
  display: flex;
  gap: 0.25rem;
  list-style: none;
  align-items: center;
}
.nav-links a {
  text-decoration: none;
  color: var(--text-secondary);
  font-size: 0.85rem;
  font-weight: 500;
  padding: 0.35rem 0.65rem;
  border-radius: 8px;
  transition: all 0.2s;
  white-space: nowrap;
}
.nav-links a:hover { color: var(--primary); background: var(--primary-light); }
.nav-links a.active { color: var(--primary); background: var(--primary-light); font-weight: 700; }

/* ===== BREADCRUMB ===== */
.breadcrumb {
  padding: 0.6rem 1rem;
  font-size: 0.8rem;
  color: var(--text-secondary);
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
}
.breadcrumb a { color: var(--primary); text-decoration: none; }
.breadcrumb span { color: var(--text-secondary); }

/* ===== HERO ===== */
.hero {
  background: linear-gradient(135deg, #3B48E0 0%, #5B6AF0 60%, #7C8AF7 100%);
  color: white;
  padding: 3rem 1rem 2.5rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 400px;
  height: 400px;
  background: rgba(255,255,255,0.05);
  border-radius: 50%;
}
.hero h1 {
  font-size: clamp(1.6rem, 4vw, 2.8rem);
  font-weight: 800;
  margin-bottom: 0.75rem;
  position: relative;
}
.hero p {
  font-size: clamp(0.9rem, 2vw, 1.05rem);
  opacity: 0.9;
  max-width: 560px;
  margin: 0 auto 1.5rem;
  position: relative;
}
.hero-tag {
  display: inline-block;
  background: rgba(255,255,255,0.2);
  color: white;
  padding: 0.3rem 0.9rem;
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 1rem;
  letter-spacing: 0.03em;
}
.hero-btns { display: flex; gap: 0.75rem; justify-content: center; flex-wrap: wrap; }

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.7rem 1.4rem;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
  border: 2px solid transparent;
  font-family: inherit;
}
.btn-primary { background: var(--primary); color: white; }
.btn-primary:hover { background: var(--primary-hover); transform: translateY(-1px); }
.btn-white { background: white; color: var(--primary); border-color: white; }
.btn-white:hover { background: var(--bg); }
.btn-outline { background: transparent; color: var(--primary); border-color: var(--primary); }
.btn-outline:hover { background: var(--primary); color: white; }
.btn-outline-white { background: transparent; color: white; border-color: rgba(255,255,255,0.6); }
.btn-outline-white:hover { background: rgba(255,255,255,0.15); }
.btn-full { width: 100%; }
.btn-green { background: var(--success); color: white; }
.btn-green:hover { background: #0EA572; }
.btn-orange { background: var(--warning); color: white; }
.btn-orange:hover { background: #D97706; }

/* ===== CARDS ===== */
.card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.5rem;
  transition: all 0.25s;
  border: 1px solid var(--border);
}
.card-link {
  text-decoration: none;
  color: inherit;
  display: block;
}
.card-link:hover .card,
.card.hover:hover { transform: translateY(-2px); box-shadow: var(--shadow-hover); }
a.card:hover { transform: translateY(-2px); box-shadow: var(--shadow-hover); }
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1rem; }
.card-grid-2 { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 1rem; }

/* ===== SECTION ===== */
.section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1rem;
}
.section-white { background: white; padding: 2rem 0; }
.section-title {
  font-size: clamp(1.2rem, 3vw, 1.6rem);
  font-weight: 800;
  margin-bottom: 1.25rem;
  color: var(--text);
}
.section-subtitle {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
}

/* ===== BADGE ===== */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.2rem 0.65rem;
  border-radius: 100px;
  font-size: 0.75rem;
  font-weight: 600;
}
.badge-primary { background: var(--primary-light); color: var(--primary); }
.badge-success { background: rgba(16, 185, 129, 0.1); color: var(--success); }
.badge-warning { background: rgba(245, 158, 11, 0.1); color: #D97706; }
.badge-danger { background: rgba(239, 68, 68, 0.1); color: var(--danger); }
.badge-gray { background: #F3F4F6; color: #6B7280; }

/* ===== TABS ===== */
.tabs-wrapper { border-bottom: 2px solid var(--border); margin-bottom: 1.5rem; }
.tabs {
  display: flex;
  gap: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.tabs::-webkit-scrollbar { display: none; }
.tab-btn {
  padding: 0.7rem 1rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-secondary);
  border: none;
  border-bottom: 3px solid transparent;
  margin-bottom: -2px;
  cursor: pointer;
  white-space: nowrap;
  background: none;
  font-family: inherit;
  transition: all 0.2s;
}
.tab-btn:hover { color: var(--primary); }
.tab-btn.active { color: var(--primary); border-bottom-color: var(--primary); }
.tab-content { display: none; }
.tab-content.active { display: block; }

/* ===== LISTS ===== */
.checklist { list-style: none; padding: 0; }
.checklist li {
  padding: 0.45rem 0;
  padding-left: 1.75rem;
  position: relative;
  border-bottom: 1px solid #f0f0f0;
  font-size: 0.9rem;
}
.checklist li:last-child { border-bottom: none; }
.checklist li::before { content: "✓"; position: absolute; left: 0; color: var(--primary); font-weight: 700; }

.steps-list { list-style: none; padding: 0; counter-reset: step-counter; }
.steps-list li {
  counter-increment: step-counter;
  padding: 0.75rem 0.75rem 0.75rem 3.5rem;
  position: relative;
  border-left: 2px solid var(--primary-light);
  margin-left: 1rem;
  margin-bottom: 0.5rem;
  background: white;
  border-radius: 0 8px 8px 0;
  font-size: 0.9rem;
}
.steps-list li::before {
  content: counter(step-counter);
  position: absolute;
  left: -1.2rem;
  top: 0.75rem;
  width: 2.4rem;
  height: 2.4rem;
  background: var(--primary);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
}

/* ===== TABLE ===== */
.table-wrap { overflow-x: auto; border-radius: var(--radius); border: 1px solid var(--border); }
table { width: 100%; border-collapse: collapse; font-size: 0.875rem; }
th, td { padding: 0.75rem 1rem; text-align: left; border-bottom: 1px solid var(--border); }
th { background: var(--primary-light); font-weight: 700; color: var(--primary); white-space: nowrap; }
tr:last-child td { border-bottom: none; }
tr:hover td { background: #fafbff; }

/* ===== ALERT ===== */
.alert {
  padding: 0.9rem 1.1rem;
  border-radius: 8px;
  margin: 1rem 0;
  font-size: 0.9rem;
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
}
.alert-info { background: var(--primary-light); border-left: 4px solid var(--primary); }
.alert-warning { background: rgba(245,158,11,0.1); border-left: 4px solid var(--warning); }
.alert-success { background: rgba(16,185,129,0.1); border-left: 4px solid var(--success); }
.alert-danger { background: rgba(239,68,68,0.1); border-left: 4px solid var(--danger); }

/* ===== QUICK LINK CARD ===== */
.quick-link {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  background: white;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  text-decoration: none;
  color: inherit;
  transition: all 0.2s;
  box-shadow: var(--shadow);
}
.quick-link:hover { transform: translateY(-2px); box-shadow: var(--shadow-hover); }
.quick-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  flex-shrink: 0;
}

/* ===== TOOL STYLES ===== */
.tool-wrap { max-width: 640px; margin: 0 auto; }
.tool-label { display: block; font-weight: 600; margin-bottom: 0.4rem; font-size: 0.9rem; }
.tool-input {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 2px solid var(--border);
  border-radius: 10px;
  font-size: 1rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s;
  background: white;
  margin-bottom: 1rem;
}
.tool-input:focus { border-color: var(--primary); }
.tool-result {
  background: linear-gradient(135deg, var(--primary-light), rgba(108,117,255,0.08));
  border: 1px solid rgba(59,72,224,0.2);
  border-radius: var(--radius);
  padding: 1.5rem;
  margin-top: 1rem;
  text-align: center;
  display: none;
}
.tool-result.show { display: block; }
.result-value { font-size: 2.5rem; font-weight: 800; color: var(--primary); line-height: 1.2; }
.result-label { font-size: 0.85rem; color: var(--text-secondary); margin-top: 0.3rem; }

.upload-area {
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  padding: 2.5rem 2rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  background: white;
}
.upload-area:hover, .upload-area.dragover {
  border-color: var(--primary);
  background: var(--primary-light);
}
.upload-icon { font-size: 2.5rem; margin-bottom: 0.5rem; }

/* ===== FOOTER ===== */
footer {
  background: #1a1a2e;
  color: #9CA3AF;
  padding: 2.5rem 1rem;
  margin-top: 3rem;
}
.footer-inner { max-width: 1200px; margin: 0 auto; text-align: center; }
.footer-logo { font-weight: 800; color: white; font-size: 1.1rem; display: block; margin-bottom: 1rem; text-decoration: none; }
.footer-links { display: flex; justify-content: center; gap: 1.25rem; flex-wrap: wrap; margin-bottom: 1rem; }
.footer-links a { color: #9CA3AF; text-decoration: none; font-size: 0.875rem; transition: color 0.2s; }
.footer-links a:hover { color: white; }
.footer-copy { font-size: 0.8rem; margin-top: 1rem; }

.site-logo{
  width: 42px;
  height: 42px;
  border-radius: 10px;
  object-fit: cover;
}

/* ===== GRID / LAYOUT ===== */
.container { max-width: 1200px; margin: 0 auto; padding: 0 1rem; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.text-muted { color: var(--text-secondary); }
.text-sm { font-size: 0.875rem; }
.text-xs { font-size: 0.8rem; }
.font-bold { font-weight: 700; }
.font-semibold { font-weight: 600; }

/* ===== CANVAS PREVIEW ===== */
#previewCanvas { max-width: 100%; border-radius: 8px; border: 1px solid var(--border); }

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .nav-links { display: none; }
  .hero { padding: 2rem 1rem; }
  .card-grid, .card-grid-2 { grid-template-columns: 1fr; }
  .tab-btn { padding: 0.6rem 0.75rem; font-size: 0.78rem; }
}
@media (max-width: 480px) {
  .result-value { font-size: 1.8rem; }
  .hero h1 { font-size: 1.5rem; }
}
