/*
 * InvoiceKit — Tabler theme overrides
 */

/* Khmer font for :lang(km) */
:lang(km) {
  font-family: 'Noto Sans Khmer', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

:lang(km) .btn,
:lang(km) .form-control,
:lang(km) .form-select,
:lang(km) .nav-link,
:lang(km) .dropdown-item,
:lang(km) .card-title,
:lang(km) .page-title,
:lang(km) .page-pretitle,
:lang(km) h1, :lang(km) h2, :lang(km) h3, :lang(km) h4, :lang(km) h5, :lang(km) h6 {
  font-family: 'Noto Sans Khmer', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* Tighten page background */
body {
  background-color: #f1f5f9;
}

/* Sidebar tweaks */
.navbar-vertical {
  background: #1e293b !important;
}

.navbar-vertical .nav-link {
  color: #94a3b8 !important;
  border-radius: 0.375rem;
  margin: 0.125rem 0.5rem;
}

.navbar-vertical .nav-link:hover {
  color: #fff !important;
  background: rgba(255,255,255,0.08);
}

.navbar-vertical .nav-link.active {
  color: #fff !important;
  background: #3b82f6 !important;
}

/* Cards */
.card {
  border: none;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04), 0 1px 2px rgba(0,0,0,0.06);
  border-radius: 0.5rem;
}

.card-header {
  background: transparent;
  border-bottom: 1px solid #e2e8f0;
}

/* Stat cards */
.card .h1 {
  font-size: 1.75rem;
  font-weight: 700;
}

.card .subheader {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #64748b;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.card-footer {
  background: transparent;
  border-top: 1px solid #f1f5f9;
  padding: 0.5rem 1rem;
}

/* Page header */
.page-pretitle {
  color: #64748b;
}

.page-title {
  font-weight: 700;
  color: #1e293b;
}

/* Tables */
.table thead th {
  background: #f8fafc;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #64748b;
  font-weight: 600;
  border-bottom: 1px solid #e2e8f0;
}

.card-table {
  margin-bottom: 0;
}

/* Badges */
.badge {
  font-weight: 600;
  font-size: 0.7rem;
}

/* Footer */
.footer {
  border-top: 1px solid #e2e8f0;
}

/* Tighten spacing */
.page-body {
  padding-top: 1.5rem;
  padding-bottom: 1.5rem;
}

.page-header {
  padding: 1rem 0;
}

/* Avatar */
.avatar {
  font-weight: 700;
}

/* Button refinement */
.btn-primary {
  background: #3b82f6;
  border-color: #3b82f6;
}

.btn-primary:hover {
  background: #2563eb;
  border-color: #2563eb;
}

/* Brand in sidebar */
.navbar-brand .badge {
  background: #3b82f6 !important;
}

/* Landing page */
.landing-wrapper {
  margin: -1.5rem -1.5rem 0;
  padding: 0;
  overflow-x: hidden;
}

.landing-hero {
  background: linear-gradient(135deg, #206bc4 0%, #4263eb 50%, #7c3aed 100%);
  padding: 5rem 1rem;
}

.landing-hero-title {
  font-size: 3rem;
  line-height: 1.15;
}

.landing-cta-btn {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
  .landing-wrapper {
    margin: -1.5rem -0.75rem 0;
  }

  .landing-hero {
    padding: 3rem 0.5rem;
  }

  .landing-hero-title {
    font-size: 1.75rem;
    line-height: 1.2;
  }

  .landing-hero .lead {
    font-size: 1rem;
  }

  .landing-cta-btn {
    width: 100%;
  }

  /* Reduce section padding on mobile */
  .landing-wrapper section.py-5 {
    padding-top: 2.5rem !important;
    padding-bottom: 2.5rem !important;
  }

  .landing-wrapper .h1 {
    font-size: 1.5rem;
  }

  .landing-wrapper .fs-4 {
    font-size: 1rem !important;
  }

  /* Pricing display size */
  .landing-wrapper .display-4 {
    font-size: 2rem;
  }

  /* Footer stacking */
  .footer .row {
    flex-direction: column !important;
  }

  .footer .col-auto.ms-auto {
    margin: 0 auto !important;
  }
}
