/* 
 * ICAMSCI 2026 — Unified Paper Portal Design System
 * Integrated with Parent Site Palette & Aesthetics
 */

body.portal-body {
  background-color: #f6f3ed !important;
  color: var(--gray-800);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  margin: 0;
  padding: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.portal-main-wrapper {
  flex: 1;
  padding: 40px 0 60px 0;
}

/* ===== PORTAL HERO BANNER ===== */
.portal-hero-banner {
  background: linear-gradient(135deg, #1a0a3e 0%, #3b1d8e 60%, #4c27a3 100%);
  color: #ffffff;
  padding: 40px 0 0 0;
  position: relative;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(26, 10, 62, 0.25);
  border-bottom: 4px solid var(--gold-500);
}

.portal-hero-banner::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -10%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(212, 168, 67, 0.15) 0%, rgba(26, 10, 62, 0) 70%);
  pointer-events: none;
}

.portal-hero-flex {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 32px;
  flex-wrap: wrap;
}

.portal-badge-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  border-radius: 50px;
  background: rgba(212, 168, 67, 0.15);
  border: 1px solid rgba(212, 168, 67, 0.4);
  color: #f0d478;
  font-family: 'Space Mono', monospace;
  font-size: 0.75rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  font-weight: 700;
  margin-bottom: 12px;
}

.portal-hero-title {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 2.2rem;
  font-weight: 800;
  color: #ffffff;
  margin: 0 0 6px 0;
  line-height: 1.2;
}

.portal-hero-subtitle {
  font-size: 1rem;
  color: #c4b5fd;
  margin: 0;
  font-weight: 400;
}

.portal-hero-status-card {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
}

.status-indicator {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  backdrop-filter: blur(10px);
}

.status-open {
  background: rgba(34, 197, 94, 0.15);
  border: 1px solid rgba(34, 197, 94, 0.4);
  color: #86efac;
}

.status-closed {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #fca5a5;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 8px currentColor;
  animation: pulseDot 2s infinite;
}

@keyframes pulseDot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.3); }
}

.portal-user-badge {
  font-size: 0.85rem;
  color: #e9d5ff;
  background: rgba(255, 255, 255, 0.1);
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

/* ===== PORTAL TABS BAR ===== */
.portal-nav-tabs {
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  scrollbar-width: none;
}

.portal-nav-tabs::-webkit-scrollbar {
  display: none;
}

.portal-tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 22px;
  color: #cbd5e1;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  border-bottom: 3px solid transparent;
  transition: all 0.2s ease;
  white-space: nowrap;
  border-top-left-radius: 8px;
  border-top-right-radius: 8px;
}

.portal-tab i {
  font-size: 1.15rem;
}

.portal-tab:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
}

.portal-tab.active {
  color: #1a0a3e;
  background: #f6f3ed;
  border-bottom-color: var(--gold-500);
  font-weight: 700;
}

/* ===== CARDS & CONTAINERS ===== */
.portal-card {
  background: #ffffff;
  border-radius: 16px;
  border: 1px solid #e5e7eb;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
  margin-bottom: 32px;
  overflow: hidden;
  transition: box-shadow 0.3s ease;
}

.portal-card:hover {
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08);
}

.portal-card-header {
  padding: 24px 30px;
  background: #ffffff;
  border-bottom: 1px solid #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.portal-card-title {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--purple-900);
  margin: 0;

}

/* ===== METRICS GRID ===== */
.portal-metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-bottom: 32px;
}

.metric-card {
  background: #ffffff;
  border-radius: 16px;
  padding: 24px;
  border: 1px solid #e5e7eb;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.04);
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.metric-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 25px rgba(45, 20, 102, 0.1);
}

.metric-data .metric-value {
  font-family: 'Space Mono', monospace;
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--purple-800);
  line-height: 1.1;
}

.metric-data .metric-label {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--gray-500);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 6px;
}

.metric-icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: var(--purple-50);
  color: var(--purple-600);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
}

/* ===== TABLES ===== */
.portal-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.portal-table th {
  background: #f8fafc;
  padding: 16px 24px;
  font-family: 'Space Mono', monospace;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--gray-600);
  border-bottom: 2px solid #e2e8f0;
}

.portal-table td {
  padding: 18px 24px;
  border-bottom: 1px solid #f1f5f9;
  font-size: 0.92rem;
  color: var(--gray-800);
}

.portal-table tbody tr {
  transition: background-color 0.15s ease;
}

.portal-table tbody tr:hover {
  background-color: #f5f3ff;
}

/* ===== STATUS BADGES ===== */
.badge {
  display: inline-block;
  padding: 5px 14px;
  border-radius: 50px;
  font-family: 'Space Mono', monospace;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: #ffffff;
}

.badge-submitted { background-color: #0284c7; }
.badge-review { background-color: #d97706; }
.badge-process { background-color: #7c3aed; }
.badge-resubmit { background-color: #dc2626; }
.badge-forwarded { background-color: #059669; }
.badge-rejected { background-color: #475569; }

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 22px;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
}

.btn-primary {
  background: var(--purple-700);
  color: #ffffff !important;
}

.btn-primary:hover {
  background: var(--purple-900);
  box-shadow: 0 4px 12px rgba(45, 20, 102, 0.25);
}

.btn-gold {
  background: var(--gold-500);
  color: #1a0a3e !important;
  font-weight: 700;
}

.btn-gold:hover {
  background: var(--gold-400);
  box-shadow: 0 4px 12px rgba(212, 168, 67, 0.3);
}

.btn-secondary {
  background: #f1f5f9;
  color: var(--gray-700) !important;
  border: 1px solid #cbd5e1;
}

.btn-secondary:hover {
  background: #e2e8f0;
}

.btn-success {
  background: #059669;
  color: #ffffff !important;
}

.btn-success:hover {
  background: #047857;
}

.btn-danger {
  background: #dc2626;
  color: #ffffff !important;
}

.btn-danger:hover {
  background: #b91c1c;
}

.btn-sm {
  padding: 6px 14px;
  font-size: 0.8rem;
  border-radius: 6px;
}

/* ===== FORMS ===== */
.form-group {
  margin-bottom: 22px;
}

.form-label {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--gray-700);
}

.form-control {
  width: 100%;
  padding: 12px 16px;
  border-radius: 8px;
  border: 1.5px solid #d1d5db;
  font-size: 0.95rem;
  font-family: inherit;
  background: #ffffff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-control:focus {
  outline: none;
  border-color: var(--purple-600);
  box-shadow: 0 0 0 4px rgba(107, 63, 160, 0.12);
}

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

/* ===== ALERTS ===== */
.alert {
  padding: 18px 24px;
  border-radius: 12px;
  margin-bottom: 28px;
  font-size: 0.92rem;
  display: flex;
  align-items: center;
  gap: 14px;
}

.alert-success {
  background: #ecfdf5;
  color: #047857;
  border: 1px solid #a7f3d0;
}

.alert-danger {
  background: #fef2f2;
  color: #b91c1c;
  border: 1px solid #fecaca;
}

.alert-warning {
  background: #fffbeb;
  color: #b45309;
  border: 1px solid #fde68a;
}

/* ===== AUTH CONTAINER (LOGIN / SIGNUP) ===== */
.portal-auth-container {
  max-width: 520px;
  margin: 20px auto 40px auto;
}

.auth-card-modern {
  background: #ffffff;
  border-radius: 20px;
  padding: 44px;
  border: 1px solid #e5e7eb;
  box-shadow: 0 20px 50px rgba(26, 10, 62, 0.08);
}

.auth-card-header {
  text-align: center;
  margin-bottom: 32px;
}

.auth-card-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--purple-50);
  color: var(--purple-700);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin: 0 auto 16px auto;
}

.auth-card-title {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--purple-900);
  margin: 0 0 8px 0;
}

.auth-card-subtitle {
  font-size: 0.88rem;
  color: var(--gray-500);
  margin: 0;
}
