@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Poppins:wght@400;500;600;700&display=swap');

:root {
  --primary: #1a1a2e;
  --primary-light: #16213e;
  --primary-lighter: #0f3460;
  --accent: #e94560;
  --accent-light: #ff6b7a;
  --accent-dark: #c91f47;
  --success: #10b981;
  --warning: #f59e0b;
  --danger: #ef4444;
  --info: #3b82f6;
  --neutral-50: #f9fafb;
  --neutral-100: #f3f4f6;
  --neutral-200: #e5e7eb;
  --neutral-300: #d1d5db;
  --neutral-400: #9ca3af;
  --neutral-500: #6b7280;
  --neutral-600: #4b5563;
  --neutral-700: #374151;
  --neutral-800: #1f2937;
  --neutral-900: #111827;

  --font-primary: 'Inter', sans-serif;
  --font-display: 'Poppins', sans-serif;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.15);
  --shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.2);

  --transition-base: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  --spacing-unit: 8px;
}

*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-primary);
  font-size: 16px;
  line-height: 1.6;
  color: var(--neutral-900);
  background-color: var(--neutral-50);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: var(--transition-fast);
}

a:hover {
  color: var(--accent-light);
}

button {
  font-family: var(--font-primary);
}

img {
  max-width: 100%;
  height: auto;
}

.container {
  width: 100%;
  max-width: 1280px;
  margin-left: auto;
  margin-right: auto;
  padding-left: calc(var(--spacing-unit) * 2);
  padding-right: calc(var(--spacing-unit) * 2);
}

@media (max-width: 768px) {
  .container {
    padding-left: var(--spacing-unit);
    padding-right: var(--spacing-unit);
  }
}

header {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-md);
  position: sticky;
  top: 0;
  z-index: 1000;
  border-bottom: 1px solid rgba(233, 69, 96, 0.1);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: calc(var(--spacing-unit) * 2) 0;
  gap: calc(var(--spacing-unit) * 2);
}

.logo {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 700;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  display: flex;
  align-items: center;
  gap: calc(var(--spacing-unit) * 0.5);
}

.main-nav {
  display: flex;
  list-style: none;
  gap: calc(var(--spacing-unit) * 3);
  align-items: center;
}

.nav-link {
  color: var(--neutral-600);
  font-weight: 500;
  transition: var(--transition-fast);
  position: relative;
}

.nav-link:hover,
.nav-link.active {
  color: var(--accent);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: calc(var(--spacing-unit) * 2);
}

.lang-selector {
  position: relative;
}

.lang-selector select {
  appearance: none;
  padding: calc(var(--spacing-unit) * 0.75) calc(var(--spacing-unit) * 1);
  border: 1px solid var(--neutral-200);
  border-radius: 6px;
  background: white;
  cursor: pointer;
  font-size: 14px;
  padding-right: 28px;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 8px center;
  background-size: 16px;
}

.mobile-toggle {
  display: none;
  flex-direction: column;
  gap: 6px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
}

.mobile-toggle span {
  width: 24px;
  height: 2px;
  background: var(--accent);
  transition: var(--transition-fast);
  border-radius: 2px;
}

.mobile-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(10px, 10px);
}

.mobile-toggle.active span:nth-child(2) {
  opacity: 0;
}

.mobile-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -7px);
}

@media (max-width: 768px) {
  .main-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: var(--primary-light);
    padding: calc(var(--spacing-unit) * 2);
    box-shadow: var(--shadow-lg);
  }

  .main-nav.active {
    display: flex;
  }

  .nav-link {
    padding: calc(var(--spacing-unit) * 1.5) 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .nav-link::after {
    display: none;
  }

  .mobile-toggle {
    display: flex;
  }

  .header-inner {
    padding: var(--spacing-unit) 0;
  }
}

.hero {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  color: white;
  padding: calc(var(--spacing-unit) * 8) 0;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(233, 69, 96, 0.1) 0%, transparent 70%);
  border-radius: 50%;
}

.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: calc(var(--spacing-unit) * 4);
}

.stat-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: calc(var(--spacing-unit) * 3);
  backdrop-filter: blur(10px);
  text-align: center;
  transition: var(--transition-base);
}

.stat-card:hover {
  background: rgba(233, 69, 96, 0.1);
  border-color: rgba(233, 69, 96, 0.3);
  transform: translateY(-4px);
}

.stat-number {
  font-family: var(--font-display);
  font-size: 48px;
  font-weight: 700;
  color: var(--accent-light);
  margin-bottom: var(--spacing-unit);
}

.stat-label {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.7);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.layout-wrapper {
  display: grid;
  grid-template-columns: 300px 1fr 300px;
  gap: calc(var(--spacing-unit) * 3);
  padding: calc(var(--spacing-unit) * 4) 0;
  max-width: 1400px;
  margin: 0 auto;
}

@media (max-width: 1024px) {
  .layout-wrapper {
    grid-template-columns: 1fr;
    gap: calc(var(--spacing-unit) * 2);
  }

  .sidebar-left,
  .sidebar-right {
    display: none;
  }
}

@media (max-width: 768px) {
  .layout-wrapper {
    padding: calc(var(--spacing-unit) * 2) 0;
  }
}

.sidebar {
  display: flex;
  flex-direction: column;
  gap: calc(var(--spacing-unit) * 3);
}

.card {
  background: white;
  border-radius: 12px;
  box-shadow: var(--shadow-md);
  overflow: hidden;
  transition: var(--transition-base);
}

.card:hover {
  box-shadow: var(--shadow-lg);
}

.card-header {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
  color: white;
  padding: calc(var(--spacing-unit) * 2);
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: var(--spacing-unit);
}

.card-body {
  padding: calc(var(--spacing-unit) * 2);
}

.form-group {
  margin-bottom: calc(var(--spacing-unit) * 2);
}

.form-group:last-child {
  margin-bottom: 0;
}

label {
  display: block;
  margin-bottom: var(--spacing-unit);
  font-weight: 500;
  color: var(--neutral-700);
  font-size: 14px;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
select,
textarea {
  width: 100%;
  padding: calc(var(--spacing-unit) * 1.25);
  border: 1px solid var(--neutral-200);
  border-radius: 8px;
  font-family: var(--font-primary);
  font-size: 14px;
  transition: var(--transition-fast);
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
input[type="number"]:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(233, 69, 96, 0.1);
}

input[type="text"]:disabled,
input[type="email"]:disabled,
input[type="password"]:disabled,
input[type="number"]:disabled,
select:disabled,
textarea:disabled {
  background-color: var(--neutral-100);
  color: var(--neutral-500);
  cursor: not-allowed;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-unit);
  padding: calc(var(--spacing-unit) * 1.25) calc(var(--spacing-unit) * 2);
  font-size: 14px;
  font-weight: 600;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: var(--transition-fast);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-family: var(--font-primary);
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
  color: white;
}

.btn-primary:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 8px 16px rgba(233, 69, 96, 0.3);
}

.btn-secondary {
  background: var(--neutral-200);
  color: var(--neutral-900);
}

.btn-secondary:hover:not(:disabled) {
  background: var(--neutral-300);
}

.btn-outline {
  background: transparent;
  color: var(--accent);
  border: 2px solid var(--accent);
}

.btn-outline:hover:not(:disabled) {
  background: var(--accent);
  color: white;
}

.btn-danger {
  background: var(--danger);
  color: white;
}

.btn-danger:hover:not(:disabled) {
  background: #dc2626;
  transform: translateY(-2px);
  box-shadow: 0 8px 16px rgba(239, 68, 68, 0.3);
}

.btn-block {
  width: 100%;
}

.btn-sm {
  padding: calc(var(--spacing-unit) * 0.75) calc(var(--spacing-unit) * 1.5);
  font-size: 13px;
}

.btn-lg {
  padding: calc(var(--spacing-unit) * 1.75) calc(var(--spacing-unit) * 3);
  font-size: 16px;
}

.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.table thead {
  background: var(--neutral-100);
  border-bottom: 2px solid var(--neutral-200);
}

.table th {
  padding: calc(var(--spacing-unit) * 1.5);
  text-align: left;
  font-weight: 600;
  color: var(--neutral-700);
}

.table td {
  padding: calc(var(--spacing-unit) * 1.5);
  border-bottom: 1px solid var(--neutral-200);
}

.table tbody tr:hover {
  background-color: var(--neutral-50);
}

.table tbody tr:last-child td {
  border-bottom: none;
}

.badge {
  display: inline-block;
  padding: calc(var(--spacing-unit) * 0.5) calc(var(--spacing-unit) * 1);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.badge-success {
  background: var(--success);
  color: white;
}

.badge-warning {
  background: var(--warning);
  color: white;
}

.badge-danger {
  background: var(--danger);
  color: white;
}

.badge-info {
  background: var(--info);
  color: white;
}

.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 2000;
  align-items: center;
  justify-content: center;
  padding: var(--spacing-unit);
}

.modal.active {
  display: flex;
}

.modal-content {
  background: white;
  border-radius: 12px;
  max-width: 500px;
  width: 100%;
  box-shadow: var(--shadow-xl);
  animation: slideUp 0.3s ease;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.modal-header {
  padding: calc(var(--spacing-unit) * 2);
  border-bottom: 1px solid var(--neutral-200);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header h2 {
  margin: 0;
  font-size: 20px;
}

.modal-close {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--neutral-500);
}

.modal-body {
  padding: calc(var(--spacing-unit) * 2);
}

.modal-footer {
  padding: calc(var(--spacing-unit) * 2);
  border-top: 1px solid var(--neutral-200);
  display: flex;
  gap: var(--spacing-unit);
  justify-content: flex-end;
}

.alert {
  padding: calc(var(--spacing-unit) * 2);
  border-radius: 8px;
  margin-bottom: calc(var(--spacing-unit) * 2);
  display: flex;
  gap: var(--spacing-unit);
  align-items: flex-start;
}

.alert-success {
  background: rgba(16, 185, 129, 0.1);
  color: var(--success);
  border-left: 4px solid var(--success);
}

.alert-warning {
  background: rgba(245, 158, 11, 0.1);
  color: var(--warning);
  border-left: 4px solid var(--warning);
}

.alert-danger {
  background: rgba(239, 68, 68, 0.1);
  color: var(--danger);
  border-left: 4px solid var(--danger);
}

.alert-info {
  background: rgba(59, 130, 246, 0.1);
  color: var(--info);
  border-left: 4px solid var(--info);
}

.grid {
  display: grid;
  gap: calc(var(--spacing-unit) * 2);
}

.grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.grid-4 {
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.text-center {
  text-align: center;
}

.text-right {
  text-align: right;
}

.text-left {
  text-align: left;
}

.text-muted {
  color: var(--neutral-500);
}

.text-sm {
  font-size: 13px;
}

.text-lg {
  font-size: 18px;
}

.font-bold {
  font-weight: 700;
}

.font-semi {
  font-weight: 600;
}

.font-light {
  font-weight: 300;
}

.mt-1 { margin-top: var(--spacing-unit); }
.mt-2 { margin-top: calc(var(--spacing-unit) * 2); }
.mt-3 { margin-top: calc(var(--spacing-unit) * 3); }
.mt-4 { margin-top: calc(var(--spacing-unit) * 4); }
.mt-5 { margin-top: calc(var(--spacing-unit) * 5); }

.mb-1 { margin-bottom: var(--spacing-unit); }
.mb-2 { margin-bottom: calc(var(--spacing-unit) * 2); }
.mb-3 { margin-bottom: calc(var(--spacing-unit) * 3); }
.mb-4 { margin-bottom: calc(var(--spacing-unit) * 4); }
.mb-5 { margin-bottom: calc(var(--spacing-unit) * 5); }

.pt-1 { padding-top: var(--spacing-unit); }
.pt-2 { padding-top: calc(var(--spacing-unit) * 2); }
.pt-3 { padding-top: calc(var(--spacing-unit) * 3); }

.pb-1 { padding-bottom: var(--spacing-unit); }
.pb-2 { padding-bottom: calc(var(--spacing-unit) * 2); }
.pb-3 { padding-bottom: calc(var(--spacing-unit) * 3); }

.px-2 { padding-left: calc(var(--spacing-unit) * 2); padding-right: calc(var(--spacing-unit) * 2); }

.gap-1 { gap: var(--spacing-unit); }
.gap-2 { gap: calc(var(--spacing-unit) * 2); }
.gap-3 { gap: calc(var(--spacing-unit) * 3); }

.flex {
  display: flex;
}

.flex-col {
  flex-direction: column;
}

.flex-center {
  justify-content: center;
  align-items: center;
}

.flex-between {
  justify-content: space-between;
  align-items: center;
}

.flex-wrap {
  flex-wrap: wrap;
}

.w-full {
  width: 100%;
}

.h-full {
  height: 100%;
}

.rounded {
  border-radius: 8px;
}

.rounded-lg {
  border-radius: 12px;
}

.rounded-full {
  border-radius: 999px;
}

.border {
  border: 1px solid var(--neutral-200);
}

.bg-light {
  background: var(--neutral-50);
}

footer {
  background: var(--primary);
  color: white;
  padding: calc(var(--spacing-unit) * 4) 0 calc(var(--spacing-unit) * 2);
  margin-top: calc(var(--spacing-unit) * 8);
  border-top: 1px solid rgba(233, 69, 96, 0.1);
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: calc(var(--spacing-unit) * 4);
  margin-bottom: calc(var(--spacing-unit) * 4);
}

.footer-section h3 {
  margin-bottom: calc(var(--spacing-unit) * 2);
  color: var(--accent-light);
}

.footer-section ul {
  list-style: none;
}

.footer-section li {
  margin-bottom: var(--spacing-unit);
}

.footer-section a {
  color: rgba(255, 255, 255, 0.7);
  transition: var(--transition-fast);
}

.footer-section a:hover {
  color: var(--accent-light);
}

.footer-bottom {
  text-align: center;
  padding-top: calc(var(--spacing-unit) * 2);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.6);
  font-size: 14px;
}

.preloader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--neutral-50);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  animation: fadeOut 0.5s ease 1s forwards;
}

@keyframes fadeOut {
  to {
    opacity: 0;
    pointer-events: none;
  }
}

.spinner {
  width: 50px;
  height: 50px;
  border: 4px solid var(--neutral-200);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.breadcrumb {
  display: flex;
  gap: var(--spacing-unit);
  font-size: 14px;
  margin-bottom: calc(var(--spacing-unit) * 2);
  flex-wrap: wrap;
}

.breadcrumb a {
  color: var(--accent);
}

.breadcrumb .separator {
  color: var(--neutral-400);
}

.pagination {
  display: flex;
  gap: var(--spacing-unit);
  justify-content: center;
  margin-top: calc(var(--spacing-unit) * 4);
  flex-wrap: wrap;
}

.pagination a,
.pagination span {
  padding: calc(var(--spacing-unit) * 0.75) calc(var(--spacing-unit) * 1.25);
  border-radius: 6px;
  border: 1px solid var(--neutral-200);
  color: var(--neutral-700);
  transition: var(--transition-fast);
  font-size: 14px;
  font-weight: 500;
}

.pagination a:hover {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
}

.pagination .active {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
}

.empty-state {
  text-align: center;
  padding: calc(var(--spacing-unit) * 6) 0;
}

.empty-icon {
  font-size: 64px;
  color: var(--neutral-300);
  margin-bottom: calc(var(--spacing-unit) * 2);
}

.empty-state h3 {
  color: var(--neutral-600);
  margin-bottom: var(--spacing-unit);
}

.empty-state p {
  color: var(--neutral-500);
}

.loading {
  text-align: center;
  padding: calc(var(--spacing-unit) * 4);
}

.fade-in {
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.slide-in {
  animation: slideInLeft 0.3s ease;
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.pulse {
  animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

.mb-3 {
  margin-bottom: calc(var(--spacing-unit) * 3);
}

.font-weight-bold {
  font-weight: 700;
}

.text-white {
  color: white;
}

.bg-white {
  background: white;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  margin-bottom: calc(var(--spacing-unit) * 1.5);
}

h1 {
  font-size: 36px;
  font-weight: 700;
  line-height: 1.2;
}

h2 {
  font-size: 28px;
  font-weight: 700;
  line-height: 1.3;
}

h3 {
  font-size: 22px;
  font-weight: 600;
  line-height: 1.3;
}

h4 {
  font-size: 18px;
  font-weight: 600;
}

h5 {
  font-size: 16px;
  font-weight: 600;
}

h6 {
  font-size: 14px;
  font-weight: 600;
}

@media (max-width: 768px) {
  h1 {
    font-size: 28px;
  }

  h2 {
    font-size: 22px;
  }

  h3 {
    font-size: 18px;
  }

  .stat-card {
    padding: calc(var(--spacing-unit) * 2);
  }

  .stat-number {
    font-size: 36px;
  }
}
