/* /static/css/base.css */
:root {
  --sidebar-w: 260px;
  --header-h: 80px;
  --blue-primary: #0065D1;
  /* Updated to match the requested blue */
  --blue-hover: #0052aa;
  --gray-50: #F9FAFB;
  --gray-100: #F3F4F6;
  --gray-200: #E5E7EB;
  --gray-300: #D1D5DB;
  --gray-400: #9CA3AF;
  --gray-500: #6B7280;
  --gray-600: #4B5563;
  --gray-700: #374151;
  --gray-800: #1F2937;
  --gray-900: #111827;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  color: var(--gray-900);
  background: #fff;
}

/* Layout */
.layout {
  display: flex;
  min-height: 100vh;
}

.sidebar {
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  width: var(--sidebar-w);
  height: 100vh;
  overflow-y: auto;
  padding: 24px 16px;
  background: #fff;
  border-right: 1px solid var(--gray-200);
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.main-wrapper {
  margin-left: var(--sidebar-w);
  flex: 1;
  display: flex;
  flex-direction: column;
}

.top-header {
  height: var(--header-h);
  background: #fff;
  border-bottom: 1px solid var(--gray-200);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 32px;
}

.header-left {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.header-title {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: var(--gray-900);
}

.header-subtitle {
  margin: 0;
  font-size: 13px;
  color: var(--gray-600);
}

.header-right {
  display: flex;
  align-items: center;
}

.btn-enterprise {
  background: var(--blue-primary);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-enterprise:hover {
  background: #2563EB;
}

.content {
  padding: 32px;
  flex: 1;
  background: var(--gray-50);
}

.messages {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 16px;
}

.message {
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--gray-200);
  border-left: 4px solid var(--gray-300);
  background: #fff;
  color: var(--gray-900);
  font-size: 14px;
  font-weight: 600;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
  animation: toast-in 160ms ease-out;
}

.message.success {
  border-left-color: #16a34a;
  background: #f0fdf4;
}

.message.error {
  border-left-color: #dc2626;
  background: #fef2f2;
}

.message.info {
  border-left-color: #0284c7;
  background: #eff6ff;
}

.message.warning {
  border-left-color: #d97706;
  background: #fffbeb;
}

@keyframes toast-in {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Sidebar Header */
.sidebar-header {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--gray-900);
}

.logo svg {
  flex-shrink: 0;
}

.logo-text {
  font-size: 18px;
  font-weight: 700;
}

.search-container {
  width: 100%;
}

.search-input {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid var(--gray-300);
  border-radius: 6px;
  font-size: 14px;
  background: var(--gray-50);
  transition: border-color 0.2s;
}

.search-input:focus {
  outline: none;
  border-color: var(--blue-primary);
  background: #fff;
}

/* Navigation */
.nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 8px;
  text-decoration: none;
  color: var(--gray-700);
  font-size: 14px;
  font-weight: 500;
  transition: background 0.2s, color 0.2s;
  position: relative;
}

.nav-item:hover {
  background: var(--gray-100);
  color: var(--gray-900);
}

.nav-item.active {
  background: var(--gray-100);
  color: var(--gray-900);
  font-weight: 600;
}

.nav-item.nav-item-disabled {
  color: var(--gray-400);
  cursor: not-allowed;
  pointer-events: none;
  user-select: none;
}

.nav-item-tag {
  margin-left: auto;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--gray-100);
  font-size: 11px;
  font-weight: 600;
  color: var(--gray-600);
}

.auth-card {
  background: #fff;
  border-radius: 20px;
  padding: 32px;
  box-shadow: 0 30px 80px rgba(15, 23, 42, 0.08);
  max-width: 640px;
  margin: 0 auto;
}


.positions-card {
  background: #fff;
  border-radius: 20px;
  padding: 32px;
  box-shadow: 0 30px 80px rgba(15, 23, 42, 0.08);
  max-width: 1000px;
  /* was 740px */
  margin: 0 auto;
  width: 100%;
}

.auth-card form,
.positions-card form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.auth-card label {
  display: flex;
  flex-direction: column;
  font-size: 14px;
  font-weight: 600;
  color: var(--gray-700);
  gap: 6px;
}

.auth-card input {
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid var(--gray-300);
  font-size: 15px;
}

.auth-card input:focus {
  outline: none;
  border-color: var(--blue-primary);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.auth-card h1,
.positions-card h1 {
  margin-top: 0;
  margin-bottom: 16px;
}

.auth-card .btn,
.positions-card .btn,
.positions-card .btn-primary {
  align-self: flex-start;
}

.auth-hint {
  margin-top: 12px;
  color: var(--gray-600);
  font-size: 14px;
}

.positions-card__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}

.positions-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.positions-list li {
  padding: 16px 20px;
  border-radius: 14px;
  background: transparent;
}

.positions-list h2 {
  margin: 0;
  font-size: 18px;
}

.positions-meta {
  margin: 4px 0 0;
  color: var(--gray-600);
  font-size: 14px;
}

.positions-empty {
  margin: 0;
  color: var(--gray-600);
  text-align: center;
}

.positions-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 12px;
}

.btn-link {
  text-decoration: none;
  font-weight: 600;
  color: var(--blue-primary);
  font-size: 14px;
}

.btn-link:hover {
  text-decoration: underline;
}

.btn-link--disabled {
  color: var(--gray-400);
  pointer-events: none;
  cursor: not-allowed;
}

.nav-icon {
  flex-shrink: 0;
  color: currentColor;
}

.nav-item-dropdown {
  position: relative;
}

.dropdown-arrow {
  margin-left: auto;
  flex-shrink: 0;
  opacity: 0.5;
}

.nav-signout {
  margin-top: auto;
  padding: 0;
}

.nav-signout button {
  border: none;
  background: none;
  width: 100%;
  text-align: left;
  color: var(--gray-700);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  padding: 10px 12px;
}

.nav-signout button:hover {
  background: var(--gray-100);
  color: var(--gray-900);
}

.sidebar-footer {
  margin-top: auto;
}

.nav-user-card {
  padding: 14px 12px;
  border-radius: 12px;
  background: var(--gray-100);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nav-user-name {
  font-weight: 600;
  color: var(--gray-900);
}

.nav-user-email {
  font-size: 13px;
  color: var(--gray-600);
  word-break: break-all;
}

/* Utility Classes */
.btn-primary,
.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  transition: all 0.2s;
}

.btn-primary {
  background: var(--blue-primary);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-primary:hover {
  background: #2563EB;
}

.btn-secondary {
  background: #fff;
  color: var(--gray-700);
  border: 1px solid var(--gray-300);
  border-radius: 8px;
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-secondary:hover {
  background: var(--gray-50);
  border-color: var(--gray-400);
}

/* Auth Page Styles */
@keyframes gradient-bg {
  0% {
    background-position: 0% 50%;
  }

  50% {
    background-position: 100% 50%;
  }

  100% {
    background-position: 0% 50%;
  }
}

@keyframes float-shape {

  0%,
  100% {
    transform: translate(0, 0) rotate(0deg);
  }

  33% {
    transform: translate(30px, 50px) rotate(10deg);
  }

  66% {
    transform: translate(-20px, 20px) rotate(-5deg);
  }
}

.auth-body {
  background: linear-gradient(-45deg, #0065D1, #004b9c, #002a5c, #0088ff);
  background-size: 400% 400%;
  animation: gradient-bg 40s ease infinite;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 32px;
  font-family: 'Inter', sans-serif;
  position: relative;
  overflow: hidden;
}

/* Decorative background shapes */
.auth-shape {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  z-index: 0;
  opacity: 0.6;
  animation: float-shape 20s infinite ease-in-out;
}

.auth-shape-1 {
  top: -10%;
  left: -10%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.5) 0%, rgba(0, 0, 0, 0) 70%);
}

.auth-shape-2 {
  bottom: -10%;
  right: -10%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(6, 182, 212, 0.5) 0%, rgba(0, 0, 0, 0) 70%);
  animation-delay: -5s;
}

.auth-shape-3 {
  top: 40%;
  left: 40%;
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(139, 92, 246, 0.4) 0%, rgba(0, 0, 0, 0) 70%);
  animation-delay: -10s;
}

/* Update Auth Card for Glassmorphism */
.auth-card {
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 24px;
  padding: 40px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  max-width: 480px;
  /* Slightly narrower for a cleaner look */
  margin: 0 auto;
  position: relative;
  z-index: 1;
  width: 100%;
}

.auth-logo {
  margin-bottom: 40px;
  text-align: center;
  position: relative;
  z-index: 1;
}

.auth-logo h1 {
  color: white;
  font-size: 2.5rem;
  font-weight: 800;
  margin: 0;
  letter-spacing: -0.03em;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.auth-logo img {
  height: 64px;
  width: auto;
  display: inline-block;
  filter: drop-shadow(0 2px 10px rgba(0, 0, 0, 0.15));
}
