/* ============================================
   TPO Management Platform — Professional UI
   Modern, clean, enterprise-grade styling
   ============================================ */

/* Reset & Defaults */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, sans-serif;
  background: #ffffff;
  color: #0b1720;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
  margin: 0;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

p {
  margin: 0;
  color: #556170;
}

a {
  color: #2b7cff;
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: #1e57cc;
}

/* Containers */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ============================================
   Navigation & Header
   ============================================ */

.navbar {
  background: #ffffff;
  border-bottom: 1px solid #f0f4f8;
  padding: 16px 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(11, 35, 64, 0.04);
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  color: #0b2340;
  text-decoration: none;
}

.brand-icon {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, #2b7cff 0%, #1e57cc 100%);
  color: white;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
}

.brand-label {
  display: block;
  font-size: 0.75rem;
  color: #556170;
  font-weight: 500;
}

.brand-name {
  display: block;
  font-size: 0.95rem;
  color: #0b2340;
  font-weight: 700;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-links a {
  color: #556170;
  font-weight: 500;
  transition: color 0.2s ease;
}

.nav-links a:hover {
  color: #0b2340;
}

.nav-links .btn-login {
  padding: 8px 16px;
  border-radius: 6px;
  background: #f3f6fb;
  color: #2b7cff;
  font-weight: 600;
}

.nav-links .btn-login:hover {
  background: #e6eefc;
}

/* ============================================
   Buttons
   ============================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  border-radius: 8px;
  border: none;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, #2b7cff 0%, #1e57cc 100%);
  color: white;
  box-shadow: 0 4px 12px rgba(43, 124, 255, 0.2);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(43, 124, 255, 0.28);
}

.btn-secondary {
  background: #f3f6fb;
  color: #2b7cff;
  border: 1px solid #e6eefc;
}

.btn-secondary:hover {
  background: #e6eefc;
}

.btn-block {
  width: 100%;
}

.btn-large {
  padding: 14px 32px;
  font-size: 1rem;
}

/* ============================================
   Hero Section
   ============================================ */

.hero {
  padding: 80px 0;
  background: linear-gradient(180deg, #ffffff 0%, #f9fbfd 100%);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.hero-content h1 {
  margin-bottom: 20px;
  color: #0b2340;
  line-height: 1.15;
}

.hero-subtitle {
  font-size: 1.15rem;
  color: #556170;
  margin-bottom: 32px;
  line-height: 1.7;
}

.hero-buttons {
  display: flex;
  gap: 14px;
  margin-bottom: 48px;
}

.hero-stats {
  display: flex;
  gap: 32px;
}

.stat {
  display: flex;
  flex-direction: column;
}

.stat strong {
  font-size: 1.75rem;
  color: #2b7cff;
  margin-bottom: 4px;
}

.stat span {
  font-size: 0.85rem;
  color: #556170;
  font-weight: 500;
}

/* Dashboard Mockup */
.hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
}

.dashboard-mockup {
  width: 100%;
  max-width: 400px;
  background: white;
  border-radius: 12px;
  border: 1px solid #f0f4f8;
  box-shadow: 0 12px 32px rgba(11, 35, 64, 0.1);
  overflow: hidden;
}

.mockup-header {
  height: 44px;
  background: #f6f8fb;
  border-bottom: 1px solid #f0f4f8;
  display: flex;
  align-items: center;
  padding: 0 14px;
  gap: 10px;
}

.mockup-header span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #d4dce8;
}

.mockup-content {
  display: grid;
  grid-template-columns: 80px 1fr;
  height: 200px;
  border-top: 1px solid #f0f4f8;
}

.mockup-sidebar {
  background: #fbfdff;
  border-right: 1px solid #f0f4f8;
}

.mockup-main {
  padding: 16px;
  display: grid;
  gap: 12px;
}

.mockup-row {
  height: 8px;
  background: #e6eefc;
  border-radius: 2px;
}

.mockup-row.short {
  width: 70%;
}

/* ============================================
   Section Headers
   ============================================ */

.section-header {
  text-align: center;
  margin-bottom: 56px;
}

.section-header h2 {
  margin-bottom: 12px;
  color: #0b2340;
}

.section-header p {
  font-size: 1.1rem;
  color: #556170;
}

/* ============================================
   Features Section
   ============================================ */

.features {
  padding: 80px 0;
  background: #ffffff;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.feature-card {
  padding: 32px;
  background: #f9fbfd;
  border-radius: 12px;
  border: 1px solid #f0f4f8;
  transition: all 0.2s ease;
}

.feature-card:hover {
  border-color: #e6eefc;
  box-shadow: 0 8px 24px rgba(11, 35, 64, 0.06);
}

.feature-icon {
  font-size: 2.5rem;
  margin-bottom: 16px;
  display: block;
}

.feature-card h3 {
  margin-bottom: 12px;
  color: #0b2340;
  font-size: 1.2rem;
}

.feature-card p {
  color: #556170;
  font-size: 0.95rem;
}

/* ============================================
   Modules Section
   ============================================ */

.modules {
  padding: 80px 0;
  background: #f9fbfd;
}

.modules-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.module-item {
  padding: 28px;
  background: white;
  border-radius: 10px;
  border: 1px solid #f0f4f8;
}

.module-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, #2b7cff 0%, #1e57cc 100%);
  color: white;
  border-radius: 8px;
  font-weight: 700;
  font-size: 1.2rem;
  margin-bottom: 16px;
}

.module-item h4 {
  margin-bottom: 12px;
  color: #0b2340;
}

.module-item p {
  color: #556170;
  font-size: 0.95rem;
  line-height: 1.6;
}

/* ============================================
   Roles Section
   ============================================ */

.roles-section {
  padding: 80px 0;
  background: white;
}

.roles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.role-card {
  background: white;
  border: 1px solid #f0f4f8;
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.2s ease;
}

.role-card:hover {
  box-shadow: 0 12px 32px rgba(11, 35, 64, 0.08);
  border-color: #e6eefc;
}

.role-header {
  padding: 28px;
  color: white;
  display: flex;
  align-items: center;
  gap: 16px;
}

.student-role {
  background: linear-gradient(135deg, #0ea57a 0%, #0d8a63 100%);
}

.tpo-role {
  background: linear-gradient(135deg, #2b7cff 0%, #1e57cc 100%);
}

.admin-role {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

.role-badge {
  font-size: 1.8rem;
}

.role-header h3 {
  color: white;
  font-size: 1.4rem;
}

.role-features {
  list-style: none;
  padding: 24px 28px;
}

.role-features li {
  padding: 12px 0;
  color: #556170;
  border-bottom: 1px solid #f3f6f9;
  position: relative;
  padding-left: 24px;
}

.role-features li:last-child {
  border-bottom: none;
}

.role-features li::before {
  content: "";
  position: absolute;
  left: 0;
  color: #0ea57a;
  font-weight: 700;
}

/* ============================================
   Security Section
   ============================================ */

.security {
  padding: 80px 0;
  background: #f9fbfd;
}

.security-features {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.security-item {
  padding: 24px;
  background: white;
  border-radius: 10px;
  border: 1px solid #f0f4f8;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.security-item strong {
  color: #0b2340;
  font-size: 1rem;
}

.security-item span {
  color: #556170;
  font-size: 0.9rem;
}

/* ============================================
   CTA Section
   ============================================ */

.cta {
  padding: 80px 0;
  background: linear-gradient(135deg, #0b2340 0%, #1a3a5c 100%);
  color: white;
  text-align: center;
}

.cta-content {
  max-width: 600px;
  margin: 0 auto;
}

.cta h2 {
  color: white;
  margin-bottom: 16px;
}

.cta p {
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 32px;
  font-size: 1.1rem;
}

.cta .btn-primary {
  background: #2b7cff;
}

.cta .btn-primary:hover {
  background: #1e57cc;
}

/* ============================================
   Footer
   ============================================ */

.footer {
  background: #0b2340;
  color: white;
  padding: 48px 0 24px;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px;
  margin-bottom: 32px;
  padding-bottom: 32px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-col h4 {
  margin-bottom: 12px;
  color: white;
}

.footer-col p {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.9rem;
  line-height: 1.6;
}

.footer-col ul {
  list-style: none;
}

.footer-col li {
  margin-bottom: 8px;
}

.footer-col a {
  color: rgba(255, 255, 255, 0.7);
}

.footer-col a:hover {
  color: white;
}

.footer-bottom {
  text-align: center;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.9rem;
}

/* ============================================
   Login Page
   ============================================ */

.login-page {
  background: linear-gradient(135deg, #f9fbfd 0%, #ffffff 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
}

.login-container {
  width: 100%;
  max-width: 420px;
  padding: 24px;
}

.login-box {
  background: white;
  border-radius: 12px;
  border: 1px solid #f0f4f8;
  padding: 48px 32px;
  box-shadow: 0 12px 32px rgba(11, 35, 64, 0.08);
}

.login-header {
  text-align: center;
  margin-bottom: 32px;
}

.brand-icon-login {
  width: 56px;
  height: 56px;
  background: linear-gradient(135deg, #2b7cff 0%, #1e57cc 100%);
  color: white;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.3rem;
  margin: 0 auto 16px;
}

.login-header h1 {
  color: #0b2340;
  margin-bottom: 4px;
}

.login-header p {
  color: #556170;
  font-size: 0.95rem;
}

/* Form Styles */
.login-form {
  display: grid;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group label {
  color: #0b2340;
  font-weight: 600;
  font-size: 0.9rem;
}

.form-group input {
  padding: 11px 14px;
  border: 1px solid #e6eefc;
  border-radius: 8px;
  font-size: 0.95rem;
  font-family: inherit;
  transition: all 0.2s ease;
}

.form-group input:focus {
  outline: none;
  border-color: #2b7cff;
  box-shadow: 0 0 0 3px rgba(43, 124, 255, 0.1);
}

.form-group input::placeholder {
  color: #556170;
}

.form-remember {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: -8px;
}

.form-remember label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-weight: normal;
  margin: 0;
}

.form-remember input {
  width: 16px;
  height: 16px;
  cursor: pointer;
}

.form-remember span {
  color: #556170;
  font-size: 0.9rem;
}

.login-divider {
  text-align: center;
  color: #556170;
  font-size: 0.85rem;
  margin: 24px 0;
  position: relative;
}

.login-divider::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1px;
  background: #f0f4f8;
  z-index: 0;
}

.login-divider {
  position: relative;
  z-index: 1;
  background: white;
  padding: 0 12px;
}

.demo-accounts {
  display: grid;
  gap: 10px;
}

.demo-btn {
  padding: 12px;
  background: #f9fbfd;
  border: 1px solid #f0f4f8;
  border-radius: 8px;
  cursor: pointer;
  text-align: left;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.demo-btn:hover {
  background: #f3f6fb;
  border-color: #e6eefc;
}

.demo-btn span {
  color: #0b2340;
  font-weight: 600;
  font-size: 0.95rem;
}

.demo-btn small {
  color: #556170;
  font-size: 0.85rem;
}

.login-footer {
  text-align: center;
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid #f0f4f8;
}

.login-footer p {
  color: #556170;
  font-size: 0.9rem;
}

.login-footer a {
  color: #2b7cff;
  font-weight: 600;
}

.form-message {
  padding: 12px 14px;
  border-radius: 8px;
  font-size: 0.9rem;
  margin-top: 16px;
}

.form-message.error {
  background: #fee;
  color: #c33;
  border: 1px solid #fcc;
}

.form-message.success {
  background: #efe;
  color: #3c3;
  border: 1px solid #cfc;
}

/* ============================================
   Responsive Design
   ============================================ */

@media (max-width: 768px) {
  h1 { font-size: 2rem; }
  h2 { font-size: 1.6rem; }

  .nav-links {
    gap: 16px;
  }

  .hero-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .features-grid,
  .modules-grid,
  .roles-grid {
    grid-template-columns: 1fr;
  }

  .hero-buttons {
    flex-direction: column;
  }

  .hero-buttons .btn {
    width: 100%;
  }

  .security-features {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-content {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .login-box {
    padding: 32px 24px;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 16px;
  }

  h1 { font-size: 1.6rem; }
  h2 { font-size: 1.3rem; }

  .nav-links {
    gap: 12px;
    font-size: 0.85rem;
  }

  .hero {
    padding: 48px 0;
  }

  .hero-stats {
    flex-direction: column;
    gap: 16px;
  }

  .hero-subtitle {
    font-size: 1rem;
  }

  .features,
  .modules,
  .roles-section,
  .security,
  .cta {
    padding: 48px 0;
  }

  .section-header {
    margin-bottom: 32px;
  }

  .security-features {
    grid-template-columns: 1fr;
  }
}

/* Student Signup System - Premium Styling */
.login-container.signup-mode {
  max-width: 800px;
  transition: max-width 0.3s ease;
}

.signup-box {
  display: none;
}

.login-container.signup-mode .login-box {
  display: none;
}

.login-container.signup-mode .signup-box {
  display: block;
  background: white;
  border-radius: 12px;
  border: 1px solid #f0f4f8;
  padding: 40px 32px;
  box-shadow: 0 12px 32px rgba(11, 35, 64, 0.08);
}

.step-indicator {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 40px;
  position: relative;
  padding: 0 10px;
}

.step-indicator::before {
  content: "";
  position: absolute;
  top: 18px;
  left: 20px;
  right: 20px;
  height: 2px;
  background: #f0f4f8;
  z-index: 0;
}

.step-dot {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: white;
  border: 2px solid #e6eefc;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.95rem;
  color: #556170;
  position: relative;
  z-index: 1;
  transition: all 0.3s ease;
}

.step-dot.active {
  border-color: #2b7cff;
  color: #2b7cff;
  box-shadow: 0 0 0 4px rgba(43, 124, 255, 0.15);
}

.step-dot.completed {
  background: #2b7cff;
  border-color: #2b7cff;
  color: white;
}

.step-label {
  position: absolute;
  top: 44px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #556170;
  white-space: nowrap;
}

.step-dot.active .step-label {
  color: #2b7cff;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

@media (max-width: 600px) {
  .form-grid {
    grid-template-columns: 1fr;
  }
}

.form-grid-full {
  grid-column: 1 / -1;
}

.step-content {
  display: none;
  animation: signupFadeIn 0.3s ease;
}

.step-content.active {
  display: block;
}

@keyframes signupFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.step-actions {
  display: flex;
  justify-content: space-between;
  margin-top: 32px;
  padding-top: 20px;
  border-top: 1px solid #f0f4f8;
}

.upload-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

@media (max-width: 600px) {
  .upload-grid {
    grid-template-columns: 1fr;
  }
}

.upload-card {
  border: 1px dashed #c8d6e5;
  border-radius: 8px;
  padding: 16px;
  background: #fcfdfe;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  position: relative;
}

.upload-card:hover {
  border-color: #2b7cff;
  background: #f3f8ff;
}

.upload-card input[type="file"] {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}

.upload-icon {
  width: 36px;
  height: 36px;
  background: #e6eefc;
  color: #2b7cff;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
  transition: all 0.3s ease;
}

.upload-card.success .upload-icon {
  background: #e8f5e9;
  color: #2e7d32;
}

.upload-info {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.upload-info label {
  font-weight: 600;
  font-size: 0.85rem;
  color: #0b2340;
  cursor: pointer;
}

.upload-info span {
  font-size: 0.75rem;
  color: #556170;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

