:root {
  /* Primary Colors */
  --vivo-primary: #1f2937;
  --vivo-primary-dark: #111827;
  --vivo-primary-light: #374151;

  /* Accent Colors */
  --vivo-accent: #2563EB;
  --vivo-accent-light: #3B82F6;
  --vivo-accent-dark: #1D4ED8;

  /* Surface Colors */
  --vivo-surface: #ffffff;
  --vivo-surface-light: #F9FAFB;
  --vivo-surface-dark: #F3F4F6;

  /* Status Colors - Metric Cards */
  --vivo-metric-customers: #DDD6FE;
  --vivo-metric-products: #D1E7F5;
  --vivo-metric-orders: #DBEAFE;
  --vivo-metric-revenue: #FCE7F3;
  --vivo-metric-stock: #E0E7FF;

  /* Status Colors - Icons */
  --vivo-metric-customers-icon: #8B5CF6;
  --vivo-metric-products-icon: #06B6D4;
  --vivo-metric-orders-icon: #10B981;
  --vivo-metric-revenue-icon: #F97316;
  --vivo-metric-stock-icon: #6366F1;

  /* Text Colors */
  --vivo-text-primary: #111827;
  --vivo-text-secondary: #6B7280;
  --vivo-text-tertiary: #9CA3AF;

  /* Border Colors */
  --vivo-border: #E5E7EB;
  --vivo-border-light: #F3F4F6;

  /* Semantic Colors */
  --vivo-success: #10B981;
  --vivo-warning: #F97316;
  --vivo-danger: #EF4444;
  --vivo-info: #0EA5E9;
}

/* Modern Admin Layout Styles */
.admin-shell {
  background-color: var(--vivo-surface-light);
}

.admin-topbar {
  background-color: var(--vivo-surface);
  border-bottom: 1px solid var(--vivo-border);
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
}

.admin-icon-menu {
  background-color: var(--vivo-surface);
  border-right: 1px solid var(--vivo-border);
}

.admin-menu-link {
  color: var(--vivo-text-secondary);
  transition: all 0.2s ease;
}

.admin-menu-link:hover,
.admin-menu-link.active {
  color: var(--vivo-accent);
  background-color: var(--vivo-surface-light);
}

.admin-content {
  background-color: var(--vivo-surface-light);
}

/* Metric Cards */
.metric-card {
  background-color: var(--vivo-surface);
  border-radius: 0.5rem;
  padding: 1.5rem;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  border: 1px solid var(--vivo-border-light);
  transition: all 0.3s ease;
}

.metric-card:hover {
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  transform: translateY(-2px);
}

.metric-card.metric-customers {
  background: linear-gradient(135deg, var(--vivo-metric-customers) 0%, var(--vivo-surface) 100%);
  border-left: 4px solid var(--vivo-metric-customers-icon);
}

.metric-card.metric-products {
  background: linear-gradient(135deg, var(--vivo-metric-products) 0%, var(--vivo-surface) 100%);
  border-left: 4px solid var(--vivo-metric-products-icon);
}

.metric-card.metric-orders {
  background: linear-gradient(135deg, var(--vivo-metric-orders) 0%, var(--vivo-surface) 100%);
  border-left: 4px solid var(--vivo-metric-orders-icon);
}

.metric-card.metric-revenue {
  background: linear-gradient(135deg, var(--vivo-metric-revenue) 0%, var(--vivo-surface) 100%);
  border-left: 4px solid var(--vivo-metric-revenue-icon);
}

.metric-card.metric-stock {
  background: linear-gradient(135deg, var(--vivo-metric-stock) 0%, var(--vivo-surface) 100%);
  border-left: 4px solid var(--vivo-metric-stock-icon);
}

.metric-icon {
  width: 3rem;
  height: 3rem;
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.metric-customers .metric-icon {
  background-color: var(--vivo-metric-customers);
  color: var(--vivo-metric-customers-icon);
}

.metric-products .metric-icon {
  background-color: var(--vivo-metric-products);
  color: var(--vivo-metric-products-icon);
}

.metric-orders .metric-icon {
  background-color: var(--vivo-metric-orders);
  color: var(--vivo-metric-orders-icon);
}

.metric-revenue .metric-icon {
  background-color: var(--vivo-metric-revenue);
  color: var(--vivo-metric-revenue-icon);
}

.metric-stock .metric-icon {
  background-color: var(--vivo-metric-stock);
  color: var(--vivo-metric-stock-icon);
}

.metric-label {
  font-size: 0.875rem;
  color: var(--vivo-text-secondary);
  margin-bottom: 0.5rem;
}

.metric-value {
  font-size: 1.875rem;
  font-weight: 700;
  color: var(--vivo-text-primary);
  margin-bottom: 0.5rem;
}

.metric-change {
  font-size: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.metric-change.positive {
  color: var(--vivo-success);
}

.metric-change.negative {
  color: var(--vivo-danger);
}

/* Modern Buttons */
.btn-primary {
  background-color: var(--vivo-accent);
  border-color: var(--vivo-accent);
  color: var(--vivo-surface);
  transition: all 0.2s ease;
}

.btn-primary:hover {
  background-color: var(--vivo-accent-dark);
  border-color: var(--vivo-accent-dark);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

/* Filter Controls */
.filter-control {
  background-color: var(--vivo-surface);
  border: 1px solid var(--vivo-border);
  border-radius: 0.5rem;
  padding: 1.25rem;
  margin-bottom: 1.5rem;
}

.filter-button {
  background-color: var(--vivo-accent);
  color: var(--vivo-surface);
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 0.375rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.filter-button:hover {
  background-color: var(--vivo-accent-dark);
}

/* Data Table Styles */
.data-table {
  background-color: var(--vivo-surface);
  border-radius: 0.5rem;
  overflow: hidden;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

.data-table thead {
  background-color: var(--vivo-surface-light);
  border-bottom: 2px solid var(--vivo-border);
}

.data-table th {
  color: var(--vivo-text-primary);
  font-weight: 600;
  padding: 1rem;
  text-align: left;
}

.data-table td {
  padding: 1rem;
  border-bottom: 1px solid var(--vivo-border-light);
  color: var(--vivo-text-primary);
}

.data-table tbody tr:hover {
  background-color: var(--vivo-surface-light);
}

/* Status Badges */
.badge-success {
  background-color: rgba(16, 185, 129, 0.1);
  color: var(--vivo-success);
  padding: 0.25rem 0.75rem;
  border-radius: 0.25rem;
  font-size: 0.75rem;
  font-weight: 600;
}

.badge-warning {
  background-color: rgba(249, 115, 22, 0.1);
  color: var(--vivo-warning);
  padding: 0.25rem 0.75rem;
  border-radius: 0.25rem;
  font-size: 0.75rem;
  font-weight: 600;
}

.badge-danger {
  background-color: rgba(239, 68, 68, 0.1);
  color: var(--vivo-danger);
  padding: 0.25rem 0.75rem;
  border-radius: 0.25rem;
  font-size: 0.75rem;
  font-weight: 600;
}

.vivo-admin-home {
  min-height: 320px;
  display: grid;
  align-items: center;
  border-top: 4px solid var(--vivo-accent);
}

/* Dashboard Styles */
.admin-dashboard-page {
  padding: 2rem;
  max-width: 1920px;
  margin: 0 auto;
}

.admin-page-title {
  color: var(--vivo-text-primary);
  font-size: 1.875rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.admin-page-description {
  color: var(--vivo-text-secondary);
  font-size: 0.875rem;
  margin-bottom: 2rem;
}

/* Filter Card */
.admin-filter-card {
  background-color: var(--vivo-surface);
  border: 1px solid var(--vivo-border);
  border-radius: 0.5rem;
  margin-bottom: 2rem;
  overflow: hidden;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

.admin-card-head {
  background-color: var(--vivo-surface-light);
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--vivo-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
  color: var(--vivo-text-primary);
}

.admin-card-head button {
  background: none;
  border: none;
  font-size: 0.75rem;
  color: var(--vivo-text-secondary);
  cursor: pointer;
  padding: 0.5rem;
}

.admin-report-filter {
  padding: 1.5rem;
  display: flex;
  gap: 1rem;
  align-items: center;
}

.admin-report-filter input {
  flex: 1;
  max-width: 300px;
  padding: 0.625rem 1rem;
  border: 1px solid var(--vivo-border);
  border-radius: 0.375rem;
  color: var(--vivo-text-primary);
}

.admin-report-filter button,
.admin-report-filter a {
  padding: 0.625rem 1rem;
  border-radius: 0.375rem;
  border: none;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.2s ease;
  text-decoration: none;
}

.btn-info {
  background-color: var(--vivo-accent);
  color: var(--vivo-surface);
}

.btn-info:hover {
  background-color: var(--vivo-accent-dark);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.btn-muted {
  background-color: transparent;
  color: var(--vivo-text-secondary);
  border: 1px solid var(--vivo-border);
}

.btn-muted:hover {
  background-color: var(--vivo-surface-light);
}

/* Metric Row */
.admin-metric-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.admin-metric {
  background: linear-gradient(135deg, var(--vivo-surface) 0%, var(--vivo-surface-light) 100%);
  border: 1px solid var(--vivo-border);
  border-radius: 0.5rem;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
}

.admin-metric:hover {
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  transform: translateY(-2px);
}

.admin-metric i {
  font-size: 1.5rem;
  color: var(--vivo-accent);
  margin-bottom: 0.75rem;
}

.admin-metric strong {
  font-size: 1.875rem;
  font-weight: 700;
  color: var(--vivo-text-primary);
  margin-bottom: 0.5rem;
}

.admin-metric span {
  font-size: 0.875rem;
  color: var(--vivo-text-secondary);
}

/* Metric specific colors */
.admin-metric:nth-child(1) i {
  color: var(--vivo-metric-customers-icon);
}

.admin-metric:nth-child(2) i {
  color: var(--vivo-metric-products-icon);
}

.admin-metric:nth-child(3) i {
  color: var(--vivo-metric-orders-icon);
}

.admin-metric:nth-child(4) i {
  color: var(--vivo-metric-revenue-icon);
}

.admin-metric:nth-child(5) i,
.admin-metric:nth-child(6) i {
  color: var(--vivo-metric-stock-icon);
}

/* Table Card */
.admin-table-card {
  background-color: var(--vivo-surface);
  border: 1px solid var(--vivo-border);
  border-radius: 0.5rem;
  margin-bottom: 2rem;
  overflow: hidden;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

/* Data Table */
.admin-data-table {
  width: 100%;
  border-collapse: collapse;
  background-color: var(--vivo-surface);
}

.admin-data-table thead {
  background-color: var(--vivo-surface-light);
  border-bottom: 2px solid var(--vivo-border);
}

.admin-data-table th {
  padding: 1rem 1.5rem;
  text-align: left;
  font-weight: 600;
  color: var(--vivo-text-primary);
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.admin-data-table td {
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--vivo-border-light);
  color: var(--vivo-text-primary);
}

.admin-data-table tbody tr:hover {
  background-color: var(--vivo-surface-light);
}

.admin-data-table tbody tr:last-child td {
  border-bottom: none;
}

/* Table Toolbar */
.admin-table-toolbar {
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--vivo-border-light);
  display: flex;
  gap: 1rem;
  align-items: center;
  background-color: var(--vivo-surface-light);
}

.admin-table-toolbar select {
  padding: 0.5rem 0.75rem;
  border: 1px solid var(--vivo-border);
  border-radius: 0.375rem;
  background-color: var(--vivo-surface);
  color: var(--vivo-text-primary);
}

.admin-table-toolbar label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--vivo-text-secondary);
}

.admin-table-toolbar input {
  padding: 0.5rem 0.75rem;
  border: 1px solid var(--vivo-border);
  border-radius: 0.375rem;
  background-color: var(--vivo-surface);
  color: var(--vivo-text-primary);
}

/* Table Grid */
.admin-table-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 2rem;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .admin-metric-row {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  }

  .admin-table-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .admin-dashboard-page {
    padding: 1rem;
  }

  .admin-page-title {
    font-size: 1.5rem;
  }

  .admin-metric-row {
    grid-template-columns: 1fr;
  }

  .admin-report-filter {
    flex-direction: column;
    align-items: stretch;
  }

  .admin-report-filter input {
    max-width: 100%;
  }
}

/* Modern Form & Input Styles */
.admin-content input[type="text"],
.admin-content input[type="email"],
.admin-content input[type="password"],
.admin-content input[type="number"],
.admin-content input[type="date"],
.admin-content input[type="time"],
.admin-content input[type="search"],
.admin-content textarea,
.admin-content select {
  width: 100%;
  padding: 0.625rem 0.875rem;
  border: 1px solid var(--vivo-border);
  border-radius: 0.375rem;
  background-color: var(--vivo-surface);
  color: var(--vivo-text-primary);
  font-family: inherit;
  font-size: 0.875rem;
  transition: all 0.2s ease;
}

.admin-content input[type="text"]:focus,
.admin-content input[type="email"]:focus,
.admin-content input[type="password"]:focus,
.admin-content input[type="number"]:focus,
.admin-content input[type="date"]:focus,
.admin-content input[type="time"]:focus,
.admin-content input[type="search"]:focus,
.admin-content textarea:focus,
.admin-content select:focus {
  outline: none;
  border-color: var(--vivo-accent);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.admin-content textarea {
  resize: vertical;
  min-height: 100px;
}

/* Button Variations */
.admin-content button,
.admin-content .btn,
.admin-content [role="button"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.625rem 1rem;
  border: none;
  border-radius: 0.375rem;
  font-weight: 500;
  font-size: 0.875rem;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.admin-content button:disabled,
.admin-content .btn:disabled,
.admin-content [role="button"]:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Primary Button */
.admin-content .btn-primary,
.admin-content button[type="submit"] {
  background-color: var(--vivo-accent);
  color: var(--vivo-surface);
  border: none;
}

.admin-content .btn-primary:hover:not(:disabled),
.admin-content button[type="submit"]:hover:not(:disabled) {
  background-color: var(--vivo-accent-dark);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
  transform: translateY(-1px);
}

/* Secondary Button */
.admin-content .btn-secondary,
.admin-content button[type="button"] {
  background-color: var(--vivo-surface-light);
  color: var(--vivo-text-primary);
  border: 1px solid var(--vivo-border);
}

.admin-content .btn-secondary:hover:not(:disabled),
.admin-content button[type="button"]:hover:not(:disabled) {
  background-color: var(--vivo-surface-dark);
  border-color: var(--vivo-text-secondary);
}

/* Success Button */
.btn-success {
  background-color: var(--vivo-success);
  color: var(--vivo-surface);
}

.btn-success:hover:not(:disabled) {
  background-color: #059669;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

/* Danger Button */
.btn-danger {
  background-color: var(--vivo-danger);
  color: var(--vivo-surface);
}

.btn-danger:hover:not(:disabled) {
  background-color: #DC2626;
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

/* Warning Button */
.btn-warning {
  background-color: var(--vivo-warning);
  color: var(--vivo-surface);
}

.btn-warning:hover:not(:disabled) {
  background-color: #EA580C;
  box-shadow: 0 4px 12px rgba(249, 115, 22, 0.3);
}

/* Small Button */
.btn-sm {
  padding: 0.375rem 0.75rem;
  font-size: 0.75rem;
}

/* Large Button */
.btn-lg {
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
}

/* Block Button */
.btn-block {
  width: 100%;
}

/* Icon Button */
.btn-icon {
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  display: inline-flex;
}

/* Form Groups */
.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  color: var(--vivo-text-primary);
  font-weight: 500;
  font-size: 0.875rem;
}

.form-group .form-text {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.75rem;
  color: var(--vivo-text-secondary);
}

.form-group.has-error input,
.form-group.has-error textarea,
.form-group.has-error select {
  border-color: var(--vivo-danger);
}

.form-group.has-error .form-text {
  color: var(--vivo-danger);
}

.form-group.has-success input,
.form-group.has-success textarea,
.form-group.has-success select {
  border-color: var(--vivo-success);
}

/* Checkbox & Radio */
input[type="checkbox"],
input[type="radio"] {
  width: 1rem;
  height: 1rem;
  margin-right: 0.5rem;
  cursor: pointer;
  accent-color: var(--vivo-accent);
}

.admin-content label {
  cursor: pointer;
  user-select: none;
}

/* Form Row */
.form-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
}

.form-row > * {
  margin-bottom: 0;
}

/* Alerts */
.alert {
  padding: 1rem;
  border-radius: 0.375rem;
  border: 1px solid;
  margin-bottom: 1rem;
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}

.alert-success {
  background-color: rgba(16, 185, 129, 0.1);
  border-color: var(--vivo-success);
  color: var(--vivo-success);
}

.alert-danger {
  background-color: rgba(239, 68, 68, 0.1);
  border-color: var(--vivo-danger);
  color: var(--vivo-danger);
}

.alert-warning {
  background-color: rgba(249, 115, 22, 0.1);
  border-color: var(--vivo-warning);
  color: var(--vivo-warning);
}

.alert-info {
  background-color: rgba(14, 165, 233, 0.1);
  border-color: var(--vivo-info);
  color: var(--vivo-info);
}

/* Additional Responsive Styles */
@media (max-width: 1920px) {
  .admin-dashboard-page {
    max-width: 100%;
  }
}

@media (max-width: 1366px) {
  .admin-metric-row {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1rem;
  }

  .admin-table-grid {
    gap: 1.5rem;
  }
}

@media (max-width: 1024px) {
  .admin-dashboard-page {
    padding: 1.5rem;
  }

  .admin-metric-row {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
  }

  .admin-metric {
    padding: 1rem;
  }

  .admin-metric strong {
    font-size: 1.5rem;
  }

  .admin-metric i {
    font-size: 1.25rem;
  }

  .admin-report-filter {
    gap: 0.5rem;
    flex-wrap: wrap;
  }

  .admin-report-filter input {
    max-width: 100%;
  }

  .admin-table-grid {
    grid-template-columns: 1fr;
  }

  .admin-table-toolbar {
    flex-wrap: wrap;
    gap: 0.75rem;
  }

  .admin-content button,
  .admin-content .btn {
    padding: 0.5rem 0.875rem;
    font-size: 0.8125rem;
  }
}

@media (max-width: 768px) {
  .admin-shell {
    display: flex;
    flex-direction: column;
  }

  .admin-dashboard-page {
    padding: 1rem;
  }

  .admin-page-title {
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
  }

  .admin-page-description {
    margin-bottom: 1.5rem;
  }

  .admin-metric-row {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 0.75rem;
    margin-bottom: 1rem;
  }

  .admin-metric {
    padding: 0.75rem;
  }

  .admin-metric strong {
    font-size: 1.25rem;
  }

  .admin-metric span {
    font-size: 0.75rem;
  }

  .admin-metric i {
    font-size: 1rem;
    margin-bottom: 0.5rem;
  }

  .admin-filter-card {
    margin-bottom: 1rem;
  }

  .admin-card-head {
    padding: 0.75rem 1rem;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }

  .admin-card-head button {
    align-self: flex-end;
  }

  .admin-report-filter {
    padding: 1rem;
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
  }

  .admin-report-filter input {
    max-width: 100%;
  }

  .admin-report-filter button {
    width: 100%;
  }

  .admin-content button,
  .admin-content .btn {
    padding: 0.5rem 0.75rem;
    font-size: 0.75rem;
  }

  .btn-lg {
    padding: 0.625rem 1rem;
    font-size: 0.875rem;
  }

  .admin-content input[type="text"],
  .admin-content input[type="email"],
  .admin-content input[type="password"],
  .admin-content input[type="number"],
  .admin-content input[type="date"],
  .admin-content input[type="time"],
  .admin-content input[type="search"],
  .admin-content textarea,
  .admin-content select {
    font-size: 16px; /* Prevent zoom on iOS */
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .admin-table-toolbar {
    padding: 0.75rem;
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
  }

  .admin-table-toolbar select,
  .admin-table-toolbar input {
    padding: 0.5rem;
    font-size: 0.75rem;
  }

  .admin-data-table {
    font-size: 0.75rem;
  }

  .admin-data-table th,
  .admin-data-table td {
    padding: 0.75rem;
  }

  .admin-table-grid {
    gap: 1rem;
  }

  .alert {
    padding: 0.75rem;
    font-size: 0.875rem;
  }
}

@media (max-width: 480px) {
  .admin-dashboard-page {
    padding: 0.75rem;
  }

  .admin-page-title {
    font-size: 1.25rem;
  }

  .admin-metric-row {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }

  .admin-metric {
    padding: 0.625rem;
  }

  .admin-metric strong {
    font-size: 1rem;
  }

  .admin-metric span {
    font-size: 0.625rem;
  }

  .admin-metric i {
    font-size: 0.875rem;
  }

  .admin-card-head {
    padding: 0.625rem 0.75rem;
  }

  .admin-report-filter {
    padding: 0.75rem;
  }

  .admin-report-filter button {
    padding: 0.5rem;
    font-size: 0.75rem;
  }

  .admin-content button,
  .admin-content .btn {
    padding: 0.4rem 0.625rem;
    font-size: 0.7rem;
  }

  .admin-data-table th,
  .admin-data-table td {
    padding: 0.5rem;
  }

  .admin-data-table th {
    font-size: 0.65rem;
  }

  .admin-table-toolbar {
    padding: 0.5rem;
  }
}

.admin-form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
}

.admin-form-grid label {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
  color: #475569;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.admin-form-grid input,
.admin-form-grid select,
.admin-form-grid textarea {
  min-height: 2.5rem;
  border: 1px solid #d7dce3;
  border-radius: 4px;
  padding: 0.5rem 0.625rem;
  color: #1f2937;
  font-size: 0.875rem;
  text-transform: none;
}

.admin-form-grid input[type="color"] {
  padding: 0.25rem;
}

.admin-form-grid .admin-check-row {
  align-items: center;
  flex-direction: row;
  justify-content: flex-start;
  min-height: 2.5rem;
  text-transform: none;
}

.admin-form-grid .filter-buttons {
  align-items: end;
  display: flex;
  flex-wrap: wrap;
  gap: 0.625rem;
}

.admin-delete-form {
  margin-top: 1rem;
}

/* Petro B2B admin theme */
:root {
  --vivo-admin-blue: #2563eb;
  --vivo-admin-blue-dark: #1d4ed8;
  --vivo-admin-ink: #0f1b3d;
  --vivo-admin-muted: #64748b;
  --vivo-admin-soft: #f6f8fc;
  --vivo-admin-line: #e4eaf3;
  --vivo-admin-card: #ffffff;
  --vivo-admin-shadow: 0 14px 36px rgba(15, 23, 42, 0.06);
  --vivo-admin-radius: 8px;
}

html,
body.admin-shell {
  min-height: 100%;
}

body.admin-shell {
  display: grid;
  grid-template-columns: 258px minmax(0, 1fr);
  grid-template-rows: 72px minmax(calc(100vh - 72px), auto);
  background:
    radial-gradient(circle at 74% 0%, rgba(37, 99, 235, 0.055), transparent 31rem),
    linear-gradient(180deg, #fbfcff 0%, #f5f7fb 100%);
  color: var(--vivo-admin-ink);
  font-family: Inter, "Segoe UI", Arial, sans-serif;
}

.admin-topbar {
  grid-column: 1 / -1;
  grid-row: 1;
  height: 72px;
  display: grid;
  grid-template-columns: 44px 220px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 0 28px;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid var(--vivo-admin-line);
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.04);
  color: var(--vivo-admin-ink);
  backdrop-filter: blur(18px);
}

.admin-menu-toggle {
  width: 36px;
  height: 36px;
  display: inline-grid;
  place-items: center;
  border-radius: 8px;
  color: #64748b;
  font-size: 18px;
  text-decoration: none;
}

.admin-menu-toggle:hover {
  background: #f1f5fb;
  color: var(--vivo-admin-blue);
}

.admin-brand {
  justify-self: start;
  gap: 12px;
  color: var(--vivo-admin-ink);
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 0;
}

.admin-brand:hover {
  color: var(--vivo-admin-ink);
}

.admin-brand img {
  width: 36px;
  height: 36px;
  object-fit: contain;
  filter: drop-shadow(0 6px 10px rgba(37, 99, 235, 0.18));
}

.admin-topbar-actions {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 18px;
}

.admin-search {
  width: min(330px, 28vw);
  min-height: 40px;
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  margin: 0 20px 0 0;
  padding: 0 12px;
  border: 1px solid var(--vivo-admin-line);
  border-radius: 8px;
  background: #fff;
  color: #94a3b8;
}

.admin-search input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--vivo-admin-ink);
  font-size: 14px;
}

.admin-search kbd {
  min-width: 34px;
  border: 0;
  border-radius: 6px;
  background: #f4f6fa;
  color: #9aa6bb;
  font-size: 11px;
  font-weight: 700;
  text-align: center;
  box-shadow: none;
}

.top-icon {
  width: 36px;
  height: 36px;
  display: inline-grid;
  place-items: center;
  border-radius: 9px;
  color: #52617a;
  font-size: 18px;
}

.top-icon:hover {
  background: #f3f6fb;
  color: var(--vivo-admin-blue);
}

.top-icon em {
  top: 0;
  right: 0;
  width: 17px;
  height: 17px;
  border: 2px solid #fff;
  background: #ef233c;
  font-size: 10px;
  line-height: 13px;
}

.admin-profile-menu > button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--vivo-admin-ink);
  text-align: left;
}

.admin-avatar {
  width: 40px;
  height: 40px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: #eaf1ff;
  color: var(--vivo-admin-blue);
  font-size: 13px;
  font-weight: 800;
}

.admin-profile-menu strong,
.admin-profile-menu small {
  display: block;
  line-height: 1.2;
}

.admin-profile-menu small {
  color: #7a88a0;
  font-size: 12px;
  font-weight: 500;
}

.admin-profile-dropdown {
  top: calc(100% + 12px);
  width: 190px;
  border: 1px solid var(--vivo-admin-line);
  border-radius: 8px;
  box-shadow: var(--vivo-admin-shadow);
  overflow: hidden;
}

.admin-profile-dropdown a {
  padding: 12px 14px;
  color: #334155;
}

.admin-icon-menu {
  grid-column: 1;
  grid-row: 2;
  position: sticky;
  top: 72px;
  z-index: 100;
  align-self: start;
  height: calc(100vh - 72px);
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 2px;
  padding: 18px 18px 0;
  overflow: visible !important;
  background: rgba(255, 255, 255, 0.94);
  border-right: 1px solid var(--vivo-admin-line);
  box-shadow: 12px 0 34px rgba(15, 23, 42, 0.04);
}

.admin-menu-item {
  min-height: auto;
  display: block;
}

.admin-menu-link {
  min-width: 0;
  min-height: 44px;
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  align-items: center;
  justify-items: start;
  gap: 12px;
  padding: 0 16px;
  border-radius: 7px;
  color: #53627a;
  font-size: 14px;
  font-weight: 700;
}

.admin-menu-link:hover,
.admin-menu-item:hover > .admin-menu-link,
.admin-menu-link.active {
  background: #eef4ff;
  color: var(--vivo-admin-blue);
}

.admin-icon-menu i {
  font-size: 17px;
}

.admin-submenu {
  position: static;
  display: none;
  min-width: 0;
  margin: 4px 0 8px 42px;
  padding: 4px 0;
  border: 0;
  border-left: 1px solid #dbe5f2;
  background: transparent;
  box-shadow: none;
}

.admin-menu-item:hover > .admin-submenu,
.admin-menu-item:focus-within > .admin-submenu {
  display: grid;
}

.admin-submenu a {
  padding: 7px 12px;
  color: #6b7890;
  border-radius: 6px;
  font-size: 13px;
}

.admin-submenu a:hover {
  background: #f3f7ff;
  color: var(--vivo-admin-blue);
}

.admin-submenu-nested {
  margin-left: 14px;
}

.admin-sidebar-spacer {
  flex: 1 1 auto;
  min-height: 28px;
}

.admin-collapse-link {
  flex: 0 0 auto;
  margin-top: 10px;
}

.admin-sidebar-copy {
  margin: 18px -18px 0;
  padding: 22px 26px;
  border-top: 1px solid var(--vivo-admin-line);
  color: #738099;
  font-size: 12px;
  line-height: 1.8;
}

.admin-content {
  grid-column: 2;
  grid-row: 2;
  min-width: 0;
  padding: 28px 40px 42px;
  background: transparent;
}

.admin-dashboard-page,
.admin-products-page,
.admin-product-detail-page {
  max-width: 1600px;
  margin: 0 auto;
  padding: 0;
}

.admin-page-title,
.admin-products-page > h1,
.admin-detail-card h1 {
  margin: 0 0 6px;
  color: var(--vivo-admin-ink);
  font-size: 24px;
  font-weight: 800;
  letter-spacing: 0;
}

.admin-breadcrumb,
.admin-breadcrumb-row .admin-breadcrumb {
  margin: 0 0 8px;
  color: #8a96aa;
  font-size: 13px;
  font-weight: 600;
}

.admin-breadcrumb a {
  color: var(--vivo-admin-blue);
  text-decoration: none;
}

.admin-breadcrumb a,
.admin-breadcrumb span:not(:nth-child(2)) {
  text-transform: capitalize;
}

.admin-breadcrumb span {
  margin-right: 8px;
  margin-left: 8px;
}

.admin-breadcrumb span:first-of-type {
  margin-left: 0;
}

.admin-breadcrumb + .admin-new-button,
.admin-products-page > .admin-new-button {
  top: 0;
}

.admin-new-button,
.admin-secondary-button,
.btn-info,
.btn-muted,
.toolbar-button,
.row-action,
.admin-eye-button,
.detail-action-row a,
.admin-status-form button,
.detail-submit-row button,
.settings-actions button {
  min-height: 40px;
  border: 1px solid transparent;
  border-radius: 7px;
  padding: 0 16px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: none;
}

.admin-new-button,
.btn-info,
.detail-submit-row button,
.settings-actions button {
  background: var(--vivo-admin-blue);
  color: #fff;
  box-shadow: 0 10px 22px rgba(37, 99, 235, 0.22);
}

.admin-new-button:hover,
.btn-info:hover {
  background: var(--vivo-admin-blue-dark);
  color: #fff;
}

.admin-secondary-button,
.btn-muted,
.toolbar-button {
  background: #fff;
  border-color: var(--vivo-admin-line);
  color: #34435b;
  box-shadow: none;
}

.admin-secondary-button {
  top: 0;
  right: 150px;
}

.admin-filter-card,
.admin-table-card,
.admin-detail-card,
.metric,
.module-panel,
.work-panel {
  border: 1px solid var(--vivo-admin-line);
  border-radius: var(--vivo-admin-radius);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--vivo-admin-shadow);
}

.admin-filter-card {
  margin-top: 24px;
  margin-bottom: 24px;
  overflow: hidden;
}

.admin-card-head {
  min-height: 56px;
  padding: 0 22px;
  border-bottom: 0;
  background: transparent;
  color: var(--vivo-admin-ink);
  font-size: 15px;
  font-weight: 800;
}

.admin-card-head span::before {
  content: "\e961";
  margin-right: 10px;
  color: var(--vivo-admin-blue);
  font-family: feather;
  font-weight: 400;
}

.admin-card-head button {
  color: #7c8aa2;
}

.admin-product-filter-grid,
.admin-order-filter-grid,
.payment-filter-grid {
  grid-template-columns: repeat(4, minmax(180px, 1fr));
  gap: 18px;
  padding: 0 22px 24px;
}

.admin-product-filter-grid input,
.admin-product-filter-grid select,
.admin-order-filter-grid input,
.admin-order-filter-grid select,
.payment-filter-grid input,
.payment-filter-grid select,
.admin-content input[type="text"],
.admin-content input[type="email"],
.admin-content input[type="password"],
.admin-content input[type="number"],
.admin-content input[type="date"],
.admin-content input[type="time"],
.admin-content input[type="search"],
.admin-content textarea,
.admin-content select {
  min-height: 40px;
  border: 1px solid #d9e2ef;
  border-radius: 6px;
  background: #fff;
  color: #263550;
  font-size: 14px;
}

.filter-buttons {
  grid-column: auto;
  justify-content: flex-start;
  align-items: center;
  gap: 10px;
}

.admin-metric-row {
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 18px;
  margin: 22px 0;
}

.admin-metric {
  min-height: 126px;
  display: grid;
  grid-template-columns: 60px minmax(0, 1fr);
  align-content: center;
  gap: 0 14px;
  padding: 20px;
  border: 1px solid var(--vivo-admin-line);
  border-radius: var(--vivo-admin-radius);
  background: #fff;
  box-shadow: var(--vivo-admin-shadow);
}

.admin-metric:hover {
  transform: none;
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.08);
}

.admin-metric i {
  grid-row: 1 / span 2;
  width: 54px;
  height: 54px;
  display: inline-grid;
  place-items: center;
  border-radius: 8px;
  margin: 0;
  background: #eef4ff;
  color: var(--vivo-admin-blue);
  font-size: 24px;
}

.admin-metric:nth-child(2) i { background: #e9fbf3; color: #10b981; }
.admin-metric:nth-child(3) i { background: #fff3e7; color: #f97316; }
.admin-metric:nth-child(4) i { background: #f5ecff; color: #8b5cf6; }
.admin-metric:nth-child(5) i,
.admin-metric:nth-child(6) i { background: #e9fbff; color: #06b6d4; }

.admin-metric strong {
  justify-self: start;
  margin: 16px 0 0;
  color: var(--vivo-admin-ink);
  font-size: 28px;
  font-weight: 800;
  line-height: 1.05;
}

.admin-metric span {
  justify-self: start;
  color: #687795;
  font-size: 13px;
  text-align: left;
}

.products-card-title,
.admin-table-toolbar {
  min-height: 60px;
  padding: 0 22px;
  border-bottom: 1px solid var(--vivo-admin-line);
  background: #fff;
}

.products-card-title h2,
.section-title h2,
.order-lines-card h2,
.order-status-card h2 {
  color: var(--vivo-admin-ink);
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: none;
}

.admin-table-scroll {
  width: 100%;
  overflow: auto;
}

.admin-orders-card .admin-table-scroll,
.legacy-table-card .admin-table-scroll {
  width: 100%;
  margin: 0;
}

.admin-data-table,
.legacy-admin-table {
  width: 100%;
  margin: 0;
  border-collapse: separate;
  border-spacing: 0;
  background: #fff;
  font-size: 13px;
}

.admin-data-table th,
.admin-data-table td,
.legacy-admin-table th,
.legacy-admin-table td {
  height: auto;
  padding: 14px 18px;
  border: 0;
  border-bottom: 1px solid var(--vivo-admin-line);
  color: #24324a;
  vertical-align: middle;
}

.admin-data-table th,
.legacy-admin-table th {
  background: #fbfcff;
  color: #5d6b83;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: none;
}

.admin-data-table tr:nth-child(odd) td {
  background: #fff;
}

.admin-data-table tbody tr:hover td {
  background: #f8fbff;
}

.status-label,
.status-pill-admin,
.order-status {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  border-radius: 5px;
  padding: 3px 9px;
  font-size: 12px;
  font-weight: 800;
}

.status-label.active,
.status-pill-admin.green {
  background: #dff7eb;
  color: #0a9f61;
}

.status-label.passive {
  background: #edf1f7;
  color: #69778d;
}

.order-status {
  background: #e9f1ff;
  color: var(--vivo-admin-blue);
}

.row-action,
.admin-eye-button,
.mini-action,
.row-list,
.row-delete,
.admin-row-next {
  width: 38px;
  min-width: 38px;
  height: 34px;
  min-height: 34px;
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--vivo-admin-line);
  border-radius: 6px;
  background: #fff;
  color: #52617a;
  font-size: 13px;
  text-decoration: none;
  box-shadow: none;
}

.row-action {
  width: auto;
  min-width: 88px;
}

.admin-eye-button:hover,
.row-action:hover,
.mini-action:hover {
  background: #eef4ff;
  color: var(--vivo-admin-blue);
}

/* Keep theme metadata columns aligned while action links remain compact. */
.legacy-admin-table {
  table-layout: fixed;
}

.legacy-admin-table th:nth-child(1),
.legacy-admin-table td:nth-child(1) { width: 52px; }
.legacy-admin-table th:nth-child(4),
.legacy-admin-table td:nth-child(4),
.legacy-admin-table th:nth-child(5),
.legacy-admin-table td:nth-child(5),
.legacy-admin-table th:nth-child(6),
.legacy-admin-table td:nth-child(6) { width: 125px; }
.legacy-admin-table th:nth-child(7),
.legacy-admin-table td:nth-child(7) { width: 170px; }
.legacy-admin-table th:last-child,
.legacy-admin-table td:last-child { width: 150px; }

.legacy-admin-table td a.legacy-text-action,
.legacy-admin-table td .status-label { white-space: normal; }

.customer-management-table .mini-action {
  color: #fff !important;
  font-size: 14px;
  line-height: 1;
  text-shadow: 0 1px 1px rgba(0, 0, 0, .16);
}

.customer-management-table .inline-form {
  margin: 0;
}

.customer-management-table .inline-form button.mini-action.danger {
  width: 38px;
  min-width: 38px;
  height: 34px;
  min-height: 34px;
  padding: 0;
  border: 1px solid #dc3545;
  border-radius: 6px;
  background: #dc3545;
  color: #fff;
}

.customer-management-table .inline-form button.mini-action.danger:hover:not(:disabled) {
  background: #bb2d3b;
  border-color: #bb2d3b;
  color: #fff;
}

.customer-list-page {
  min-width: 0;
  overflow-x: hidden;
}

.customer-list-page .admin-table-scroll {
  max-width: 100%;
  overflow-x: auto;
}

.customer-management-table .mini-action i {
  display: inline-block;
  width: 1em;
  text-align: center;
  font-style: normal;
}

.customer-management-table td.row-actions {
  overflow: visible;
  text-overflow: clip;
  white-space: nowrap;
}

.customer-management-table .row-actions {
  max-width: none;
  overflow: visible;
}

.customer-view-settings { position: relative; display: inline-flex; }
.customer-settings-toggle { display: inline-flex; align-items: center; gap: 7px; min-height: 38px; padding: 0 12px; border: 1px solid #dce4ef; border-radius: 6px; background: #fff; color: #52627b; }
.customer-settings-toggle:hover,
.customer-settings-toggle[aria-expanded="true"] { border-color: #a9c9fb; background: #f1f6ff; color: var(--vivo-admin-blue); }
.customer-settings-panel { position: absolute; top: calc(100% + 8px); right: 0; z-index: 20; min-width: 190px; padding: 12px; border: 1px solid var(--vivo-admin-line); border-radius: 6px; background: #fff; box-shadow: 0 12px 28px rgba(26, 53, 92, .14); }
.customer-settings-panel label { display: flex; align-items: center; gap: 8px; margin: 0; color: var(--vivo-admin-ink); font-size: 12px; white-space: nowrap; }
.customer-management-table.customer-density th,
.customer-management-table.customer-density td { padding-top: 7px; padding-bottom: 7px; }

.product-actions { position: relative; display: inline-flex; }
.product-actions-toggle { display: inline-flex; align-items: center; gap: 7px; min-width: 112px; justify-content: center; cursor: pointer; }
.product-actions-toggle > .fa-chevron-down { font-size: 10px; }
.product-actions-menu { position: absolute; top: calc(100% + 6px); right: 0; z-index: 30; display: none; min-width: 190px; padding: 6px 0; border: 1px solid var(--vivo-admin-line); border-radius: 6px; background: #fff; box-shadow: 0 12px 28px rgba(26, 53, 92, .16); }
.product-actions.is-open .product-actions-menu { display: block; }
.product-actions-menu a { display: flex; align-items: center; gap: 9px; padding: 9px 12px; color: #52627b !important; font-size: 12px; white-space: nowrap; }
.product-actions-menu a:hover { background: #f1f6ff; color: var(--vivo-admin-blue) !important; }
.product-actions-menu form { margin: 0; }
.product-actions-menu .product-action-danger { display: flex; width: 100%; align-items: center; gap: 9px; padding: 9px 12px; border: 0; background: transparent; color: #c0392b; font: inherit; font-size: 12px; text-align: left; white-space: nowrap; cursor: pointer; }
.product-actions-menu .product-action-danger:hover { background: #fff1ef; color: #a93226; }
.product-actions-menu i { width: 14px; text-align: center; }
.product-actions-menu.is-portal-open { position: fixed; z-index: 1000; display: block; margin: 0; }

.customer-form-sections { display: grid; gap: 16px; }
.customer-form-section { padding: 20px; border: 1px solid var(--vivo-admin-line); border-radius: 8px; background: #fbfcfe; }
.customer-form-section-heading { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; padding-bottom: 14px; border-bottom: 1px solid #e5ebf3; }
.customer-form-section-heading > i { display: grid; width: 34px; height: 34px; place-items: center; border-radius: 8px; background: #eaf1ff; color: var(--vivo-admin-blue); font-size: 15px; }
.customer-form-section-heading h2 { margin: 0; color: var(--vivo-admin-ink); font-size: 15px; font-weight: 800; }
.customer-form-section-heading p { margin: 3px 0 0; color: var(--vivo-admin-muted); font-size: 12px; }
.customer-form-section .detail-form-grid { margin: 0; }

@media (max-width: 760px) {
  .customer-form-section { padding: 14px; }
}

/* Customer management list: compact hierarchy and readable row actions. */
body.admin-shell .admin-content > .customer-list-page {
  width: 100%;
  max-width: 1600px;
  box-sizing: border-box;
  padding: 8px 22px 56px;
}

body.admin-shell .admin-content > .customer-list-page > .admin-breadcrumb {
  min-height: 0;
  margin-bottom: 12px;
  padding-right: 0;
}

body.admin-shell .admin-content > .customer-list-page > .admin-page-actions {
  position: static;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin: 0 0 16px;
}

body.admin-shell .admin-content > .customer-list-page .admin-filter-card {
  margin-bottom: 18px;
  border-color: #dfe8f4;
  border-radius: 12px;
  box-shadow: 0 6px 18px rgba(31, 65, 114, .045);
}

body.admin-shell .admin-content > .customer-list-page .admin-card-head {
  min-height: 48px;
  padding: 0 18px;
  color: #193765;
  font-size: 13px;
}

body.admin-shell .admin-content > .customer-list-page .admin-product-filter-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  padding: 12px 18px 18px;
}

body.admin-shell .admin-content > .customer-list-page .admin-product-filter-grid input,
body.admin-shell .admin-content > .customer-list-page .admin-product-filter-grid select {
  min-height: 38px;
  font-size: 12px;
}

body.admin-shell .admin-content > .customer-list-page .admin-product-filter-grid .filter-buttons {
  display: flex;
  align-items: center;
  gap: 8px;
}

body.admin-shell .admin-content > .customer-list-page .products-table-card {
  margin-bottom: 0;
  border-color: #dfe8f4;
  border-radius: 12px;
  box-shadow: 0 8px 22px rgba(31, 65, 114, .05);
}

body.admin-shell .admin-content > .customer-list-page .products-card-title {
  min-height: 58px;
  padding: 0 18px;
}

body.admin-shell .admin-content > .customer-list-page .customer-management-table {
  min-width: 1360px;
  table-layout: fixed;
}

body.admin-shell .admin-content > .customer-list-page .customer-management-table th,
body.admin-shell .admin-content > .customer-list-page .customer-management-table td {
  padding: 11px 12px;
  vertical-align: middle;
}

body.admin-shell .admin-content > .customer-list-page .customer-management-table td.row-actions {
  width: 250px;
  padding-right: 14px;
}

body.admin-shell .admin-content > .customer-list-page .customer-management-table .row-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
}

body.admin-shell .admin-content > .customer-list-page .customer-management-table .mini-action {
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  border-radius: 7px;
}

body.admin-shell .admin-content > .customer-list-page .customer-management-table .customer-date-cell { white-space: nowrap; color: #58708f; font-size: 11px; }
body.admin-shell .admin-content > .customer-list-page .customer-date-line { display: inline-flex; align-items: center; gap: 7px; }
body.admin-shell .admin-content > .customer-list-page .customer-date-line i { color: #2563eb; font-size: 12px; }
body.admin-shell .admin-content > .customer-list-page .customer-balance-cell { color: #1d3558; font-size: 12px; font-weight: 800; white-space: nowrap; }
body.admin-shell .admin-content > .customer-list-page .customer-balance-cell small { color: #71809a; font-size: 10px; font-weight: 700; }
body.admin-shell .admin-content > .customer-list-page .customer-actions { display: inline-flex; }
body.admin-shell .admin-content > .customer-list-page .customer-actions .product-actions-toggle { min-width: 112px; min-height: 36px; justify-content: center; }

@media (max-width: 900px) {
  body.admin-shell .admin-content > .customer-list-page .admin-product-filter-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  body.admin-shell .admin-content > .customer-list-page {
    padding: 8px 12px 40px;
  }

  body.admin-shell .admin-content > .customer-list-page .admin-product-filter-grid {
    grid-template-columns: 1fr;
  }

  body.admin-shell .admin-content > .customer-list-page > .admin-page-actions {
    justify-content: stretch;
  }

  body.admin-shell .admin-content > .customer-list-page > .admin-page-actions a {
    flex: 1;
    justify-content: center;
  }
}

/* Delivery method editor layout */
body.admin-shell .admin-content .delivery-method-form {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px 28px;
  align-items: start;
  padding: 28px 32px 30px;
}

body.admin-shell .admin-content .delivery-method-form > .form-full {
  grid-column: 1 / -1;
}

body.admin-shell .admin-content .delivery-method-form > .form-required-legend {
  width: 100%;
  box-sizing: border-box;
  margin: 0 0 2px;
}

body.admin-shell .admin-content .delivery-method-form > label {
  min-width: 0;
}

body.admin-shell .admin-content .delivery-method-form > .admin-check-row {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 9px;
  min-height: 38px;
  margin: 4px 0 0;
  padding: 0 12px;
  border: 1px solid #e1e8f2;
  border-radius: 7px;
  background: #fbfcfe;
  color: #52627b;
  font-size: 12px;
  font-weight: 700;
  text-transform: none;
}

body.admin-shell .admin-content .delivery-method-form > .admin-check-row input {
  width: 16px;
  min-height: 16px;
  accent-color: var(--vivo-admin-blue);
}

body.admin-shell .admin-content .delivery-method-form > .filter-buttons {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  margin-top: 6px;
  padding: 18px 0 0;
  border-top: 1px solid #e8eef6;
}

@media (max-width: 700px) {
  body.admin-shell .admin-content .delivery-method-form {
    grid-template-columns: 1fr;
    padding: 20px;
  }

  body.admin-shell .admin-content .delivery-method-form > .form-full {
    grid-column: auto;
  }
}

/* Product detail form: keep the first tab compact and prevent the rich-text
   field from stretching the whole grid through empty rows. */
body.admin-shell .admin-content > .admin-product-detail-page > .admin-detail-card .product-required-legend {
  margin: 2px 22px 16px;
  border: 1px solid #f4d7da;
  background: #fff8f8;
  line-height: 1.3;
}

body.admin-shell .admin-content > .admin-product-detail-page .product-tabs {
  min-width: 0;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: thin;
  white-space: nowrap;
}

body.admin-shell .admin-content > .admin-product-detail-page .product-tabs a {
  flex: 0 0 auto;
  padding-inline: 14px;
  font-size: 12px;
  font-weight: 700;
}

body.admin-shell .admin-content > .admin-product-detail-page .detail-general-panel .detail-form-grid {
  align-items: start;
  gap: 18px 20px;
}

body.admin-shell .admin-content > .admin-product-detail-page .detail-general-panel .tall {
  grid-row: auto;
}

body.admin-shell .admin-content > .admin-product-detail-page .detail-general-panel textarea {
  min-height: 116px;
  resize: vertical;
}

body.admin-shell .admin-content > .admin-product-detail-page .detail-form-grid label > span:first-child,
body.admin-shell .admin-content > .admin-product-detail-page .detail-tab-panel > h2 {
  color: #233d68;
  font-weight: 700;
}

body.admin-shell .admin-content > .admin-product-detail-page .detail-form-grid input,
body.admin-shell .admin-content > .admin-product-detail-page .detail-form-grid select,
body.admin-shell .admin-content > .admin-product-detail-page .detail-form-grid textarea {
  font-size: 13px;
}

@media (max-width: 992px) {
  body.admin-shell .admin-content > .admin-product-detail-page .product-tabs {
    margin-inline: 16px;
  }
}

.admin-login-page .form-required-legend {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin: 0 0 14px;
  padding: 6px 10px;
  border: 1px solid #f4d7da;
  border-radius: 6px;
  background: #fff8f8;
  color: #65738a;
  font-size: 12px;
}
.admin-login-page .form-required-legend strong,
.admin-login-page .required-field em { color: #dc3545; font-style: normal; font-weight: 800; }

.admin-topbar .top-icon { display: inline-grid; place-items: center; position: relative; text-decoration: none; }
.admin-profile-dropdown { display: none; }
.admin-profile-menu.is-open .admin-profile-dropdown { display: block; }
.admin-profile-menu.is-open .admin-profile-toggle .ft-chevron-down { transform: rotate(180deg); }
.admin-profile-toggle .ft-chevron-down { transition: transform .16s ease; }

/* Profile and notification controls are click-driven, not hover-driven. */
.admin-profile-menu:hover .admin-profile-dropdown { display: none; }
.admin-profile-menu.is-open:hover .admin-profile-dropdown { display: block; }

/* Submenus are intentionally opened by click so they do not disappear while scanning. */
.admin-menu-item.has-dropdown { position: relative; }
.admin-menu-item.has-dropdown > .admin-submenu {
  position: absolute;
  top: 0;
  left: calc(100% - 4px);
  z-index: 60;
  display: none;
  min-width: 250px;
  max-height: calc(100vh - 110px);
  margin: 0;
  padding: 8px 0;
  overflow: visible;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 14px 30px rgba(26, 53, 92, .16);
}
.admin-menu-item.has-dropdown:hover > .admin-submenu { display: none; }
.admin-menu-item.has-dropdown.is-open > .admin-submenu { display: block; }
.admin-menu-item.has-dropdown:focus-within > .admin-submenu { display: block; }
.admin-menu-item.has-dropdown > .admin-submenu .admin-submenu-nested {
  top: -9px;
  left: calc(100% - 1px);
}

.admin-icon-menu {
  overflow-x: hidden !important;
  overflow-y: auto !important;
  scrollbar-width: thin;
  z-index: 100 !important;
}

/* Keep nested navigation in the sidebar flow so long menus remain usable. */
.admin-menu-item.has-dropdown > .admin-submenu {
  position: static;
  display: none;
  min-width: 0;
  max-height: none;
  margin: 4px 0 8px 4px;
  padding: 4px 0;
  overflow: visible;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}
.admin-menu-item.has-dropdown:hover > .admin-submenu,
.admin-menu-item.has-dropdown:focus-within > .admin-submenu { display: none; }
.admin-menu-item.has-dropdown.is-open > .admin-submenu { display: grid; }
.admin-menu-item.has-dropdown > .admin-menu-link::after {
  content: "›";
  grid-column: 3;
  grid-row: 1;
  margin-left: auto;
  color: #91a0b8;
  font-size: 18px;
  line-height: 1;
  transform: rotate(0deg);
  transition: transform .15s ease;
}
.admin-menu-item.has-dropdown > .admin-menu-link {
  grid-template-columns: 22px minmax(0, 1fr) auto;
}
.admin-menu-item.has-dropdown.is-open > .admin-menu-link::after { transform: rotate(90deg); }
.admin-submenu-branch > a::after {
  content: "›";
  float: right;
  color: #91a0b8;
}
.admin-submenu-branch.is-open > a::after { transform: rotate(90deg); }
.admin-submenu-nested {
  position: static !important;
  display: none !important;
  margin: 2px 0 4px 14px !important;
}
.admin-submenu-branch.is-open > .admin-submenu-nested { display: grid !important; }
.admin-submenu a.active { background: #eef4ff; color: var(--vivo-admin-blue); }
.admin-menu-item:not(.finance-menu):has(> .admin-menu-link[href="/odeme_yontemleri/odeme_sekilleri/list"]),
.admin-menu-item:not(.finance-menu):has(> .admin-menu-link[href="/tahsilatlar/list"]) { display: none; }
.netsis-create {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  margin-top: 14px;
  padding: 9px 14px;
  border-radius: 6px;
  background: #2563eb;
  color: #fff !important;
  font-weight: 700;
  text-decoration: none;
}
.netsis-create:hover { background: #1d4ed8; }
.customer-addresses-page .address-empty {
  min-height: 92px;
  vertical-align: middle;
  text-align: center;
  color: #66758c;
  background: #f8fafc;
}
.customer-addresses-page .address-pager a {
  cursor: pointer;
}
.customer-addresses-page .customer-addresses-toolbar input[type="search"] {
  flex: 1 1 280px;
  min-width: 180px;
  min-height: 34px;
  padding: 7px 10px;
  border: 1px solid #d7dfeb;
  border-radius: 5px;
  background: #fff;
}
.customer-addresses-page .address-search-button,
.customer-addresses-page .address-create-button {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 7px 12px;
  border: 0;
  border-radius: 5px;
  background: #2563eb;
  color: #fff !important;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}
.customer-addresses-page .address-search-button { flex: 0 0 auto; }
.customer-addresses-page .address-create-button { margin-left: auto; background: #0f766e; min-width: 166px; justify-content: center; }
.customer-addresses-page .customer-addresses-toolbar .address-columns-button { flex: 0 0 auto; }

/* Adres listesinde günlük operasyon için gerekli alanları öne çıkar. */
.customer-addresses-page:not(.customer-permissions-page) .customer-addresses-table th:nth-child(1),
.customer-addresses-page:not(.customer-permissions-page) .customer-addresses-table td:nth-child(1),
.customer-addresses-page:not(.customer-permissions-page) .customer-addresses-table th:nth-child(2),
.customer-addresses-page:not(.customer-permissions-page) .customer-addresses-table td:nth-child(2),
.customer-addresses-page:not(.customer-permissions-page) .customer-addresses-table th:nth-child(4),
.customer-addresses-page:not(.customer-permissions-page) .customer-addresses-table td:nth-child(4),
.customer-addresses-page:not(.customer-permissions-page) .customer-addresses-table th:nth-child(9),
.customer-addresses-page:not(.customer-permissions-page) .customer-addresses-table td:nth-child(9),
.customer-addresses-page:not(.customer-permissions-page) .customer-addresses-table th:nth-child(10),
.customer-addresses-page:not(.customer-permissions-page) .customer-addresses-table td:nth-child(10),
.customer-addresses-page:not(.customer-permissions-page) .customer-addresses-table th:nth-child(11),
.customer-addresses-page:not(.customer-permissions-page) .customer-addresses-table td:nth-child(11),
.customer-addresses-page:not(.customer-permissions-page) .customer-addresses-table th:nth-child(12),
.customer-addresses-page:not(.customer-permissions-page) .customer-addresses-table td:nth-child(12) {
  display: none;
}
@media (max-width: 900px) {
  .customer-addresses-page .customer-addresses-toolbar { flex-wrap: wrap; }
  .customer-addresses-page .address-create-button { margin-left: 0; }
}

/* Sol menü masaüstünde header'ın altından ekranın altına kadar sabit uzanır. */
@media (min-width: 901px) {
  body.admin-shell .admin-icon-menu {
    position: sticky;
    top: 72px;
    align-self: start;
    height: calc(100vh - 72px);
    min-height: calc(100vh - 72px);
    overflow-y: auto !important;
  }
}

.currency-footer,
.admin-pager,
.pager {
  padding: 18px 22px;
  color: #687795;
  font-size: 13px;
}

.currency-footer button,
.currency-footer b,
.currency-footer a,
.pager a {
  min-height: 34px;
  border: 1px solid var(--vivo-admin-line);
  border-radius: 6px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  background: #fff;
  color: #52617a;
  text-decoration: none;
}

.currency-footer b {
  border-color: var(--vivo-admin-blue);
  background: var(--vivo-admin-blue);
  color: #fff;
}

.admin-detail-card,
.order-lines-card,
.order-status-card {
  padding: 22px;
}

.product-tabs a {
  min-height: 40px;
  border-color: var(--vivo-admin-line);
  border-radius: 7px 7px 0 0;
  background: #f8fbff;
  color: #5c6a81;
  font-weight: 700;
}

.product-tabs a.active {
  color: var(--vivo-admin-blue);
}

.product-tabs a.active::before {
  background: var(--vivo-admin-blue);
}

.status-code-editor {
  padding: 28px 32px 32px;
}

.status-code-editor-head {
  display: flex;
  justify-content: space-between;
  margin-bottom: 24px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--vivo-admin-line);
}

.status-code-editor-head h1 {
  margin: 4px 0 6px;
  font-size: 24px;
  font-weight: 800;
}

.status-code-editor-head p {
  margin: 0;
  color: var(--vivo-admin-muted);
}

.status-code-form {
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 20px;
}

.status-code-form > label:nth-child(1),
.status-code-form > label:nth-child(2) {
  grid-column: span 6;
}

.status-code-form > label:nth-child(3),
.status-code-form > label:nth-child(4),
.status-code-form > label:nth-child(5) {
  grid-column: span 4;
}

.status-code-form > label:nth-child(6) {
  grid-column: span 12;
}

.status-code-form .admin-check-row,
.status-code-actions {
  grid-column: span 12;
}

.status-code-form input[type="color"] {
  min-height: 42px;
  padding: 4px;
}

.offers-search-form {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  width: min(520px, 100%);
}

.offers-search-form input {
  min-width: 0;
  flex: 1;
  min-height: 38px;
  padding-left: 12px;
  border: 1px solid var(--vivo-admin-line);
  border-radius: 6px;
}

.offers-search-form button {
  min-height: 38px;
  padding: 0 16px;
  border: 0;
  border-radius: 6px;
  background: var(--vivo-admin-blue);
  color: #fff;
  font-weight: 700;
}

.reference-actions .row-action {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.admin-order-info-table {
  border: 1px solid var(--vivo-admin-line);
  border-radius: 0 7px 7px 7px;
  overflow: hidden;
}

.admin-order-info-table div {
  min-height: 42px;
  border-bottom: 1px solid var(--vivo-admin-line);
  color: #65748c;
  font-size: 13px;
}

.admin-order-info-table b {
  color: var(--vivo-admin-ink);
}

.admin-order-tabs {
  margin: 0 22px 18px;
}

.admin-order-tabs a {
  min-height: 34px;
  border: 1px solid #cfe0ff;
  border-radius: 6px;
  color: var(--vivo-admin-blue);
  font-weight: 800;
}

.admin-order-tabs a.active {
  background: var(--vivo-admin-blue);
  color: #fff;
}

.admin-notice {
  margin: 16px 0;
  border: 1px solid #bdebd5;
  border-left: 4px solid #10b981;
  border-radius: 7px;
  background: #edfbf5;
  color: #08784a;
  box-shadow: none;
}

@media (max-width: 1280px) {
  body.admin-shell {
    grid-template-columns: 228px minmax(0, 1fr);
  }

  .admin-content {
    padding: 24px;
  }

  .admin-metric-row {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .admin-product-filter-grid,
  .admin-order-filter-grid,
  .payment-filter-grid {
    grid-template-columns: repeat(2, minmax(180px, 1fr));
  }
}

@media (max-width: 900px) {
  body.admin-shell {
    display: block;
  }

  .admin-topbar {
    position: sticky;
    top: 0;
    z-index: 30;
    grid-template-columns: 36px minmax(0, 1fr);
    padding: 0 16px;
  }

  .admin-search,
  .top-icon,
  .admin-profile-menu small {
    display: none;
  }

  .admin-icon-menu {
    position: static;
    height: auto;
    max-height: none;
    border-right: 0;
    border-bottom: 1px solid var(--vivo-admin-line);
  }

  .admin-content {
    padding: 18px;
  }

  .admin-metric-row,
  .admin-product-filter-grid,
  .admin-order-filter-grid,
  .payment-filter-grid {
    grid-template-columns: 1fr;
  }
}

/* Shared screen language for the remaining list, detail, form, and settings views. */
:root {
  --vivo-admin-blue: #2874e8;
  --vivo-admin-blue-dark: #1559c8;
  --vivo-admin-ink: #16233d;
  --vivo-admin-muted: #6e7c95;
  --vivo-admin-line: #e4eaf2;
  --vivo-admin-soft: #f7f9fc;
  --vivo-admin-radius: 8px;
  --vivo-admin-shadow: 0 3px 14px rgba(26, 53, 92, .045);
}

body.admin-shell,
body.admin-shell input,
body.admin-shell select,
body.admin-shell textarea,
body.admin-shell button {
  font-family: Inter, "Segoe UI", Arial, sans-serif;
}

body.admin-shell {
  color: var(--vivo-admin-ink);
  background: #f8faff;
}

body.admin-menu-collapsed {
  grid-template-columns: 76px minmax(0, 1fr);
}

body.admin-menu-collapsed .admin-icon-menu {
  width: 76px;
}

body.admin-menu-collapsed .admin-menu-link span,
body.admin-menu-collapsed .admin-sidebar-copy,
body.admin-menu-collapsed .admin-submenu {
  display: none;
}

body.admin-menu-collapsed .admin-menu-link {
  justify-content: center;
}

body.admin-menu-collapsed .admin-menu-link i {
  margin: 0;
}

body.admin-shell h1,
body.admin-shell h2,
body.admin-shell h3,
body.admin-shell h4,
body.admin-shell h5,
body.admin-shell h6,
body.admin-shell .products-card-title,
body.admin-shell .legacy-card-title {
  font-family: Inter, "Segoe UI", Arial, sans-serif !important;
}

.admin-content > section,
.admin-dashboard-page,
.admin-products-page,
.admin-settings-page,
.admin-module-page,
.admin-detail-page,
.admin-product-detail-page {
  width: 100%;
  max-width: 1600px;
  margin: 0 auto;
}

.admin-page-title,
.admin-products-page h1,
.admin-products-page h2,
.admin-settings-page h1,
.admin-detail-card h1,
.legacy-card-title h2,
.products-card-title h2,
.management-card .products-card-title h2 {
  color: var(--vivo-admin-ink);
  letter-spacing: 0;
}

.admin-breadcrumb,
.admin-page-description,
.admin-dashboard-page .admin-page-title + p {
  color: var(--vivo-admin-muted);
}

.admin-breadcrumb a,
.admin-content a:not(.btn-info):not(.btn-muted):not(.admin-new-button):not(.admin-secondary-button):not(.toolbar-button):not(.row-action):not(.mini-action):not(.admin-eye-button):not(.admin-row-next):not(.legacy-text-action) {
  color: var(--vivo-admin-blue);
}

.admin-filter-card,
.admin-table-card,
.admin-detail-card,
.settings-card,
.currency-card,
.management-card,
.legacy-table-card,
.product-import-card,
.order-detail-card,
.order-lines-card,
.order-status-card {
  border: 1px solid var(--vivo-admin-line);
  border-radius: var(--vivo-admin-radius);
  background: #fff;
  box-shadow: var(--vivo-admin-shadow);
}

.admin-filter-card,
.admin-table-card {
  overflow: hidden;
}

.admin-card-head,
.products-card-title,
.legacy-card-title,
.admin-table-toolbar {
  background: #fff;
  border-color: var(--vivo-admin-line);
}

.admin-card-head {
  min-height: 52px;
  padding: 0 20px;
  color: var(--vivo-admin-ink);
  font-size: 13px;
}

.admin-card-head span {
  color: var(--vivo-admin-ink);
  font-weight: 800;
}

.admin-card-head button {
  color: var(--vivo-admin-muted);
}

/* Masaüstünde yalnızca içerik alanı kayar; üst başlık ve sol menü sabit kalır. */
@media (min-width: 901px) {
  html:has(body.admin-shell),
  body.admin-shell {
    height: 100%;
    overflow: hidden;
  }

  body.admin-shell {
    height: 100vh;
    grid-template-rows: 72px minmax(0, 1fr);
  }

  body.admin-shell .admin-icon-menu {
    position: static;
    height: auto;
    min-height: 0;
    overflow-y: auto !important;
  }

  body.admin-shell .admin-content {
    height: auto;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
  }

  body.admin-shell .admin-icon-menu {
    grid-row: 2;
    align-self: stretch;
    height: 100%;
    max-height: calc(100vh - 72px);
    min-height: 0;
    overflow-x: hidden !important;
    overflow-y: auto !important;
  }
}

@media (max-width: 900px) {
  html:has(body.admin-shell),
  body.admin-shell {
    height: auto;
    overflow: visible;
  }

  body.admin-shell .admin-content {
    height: auto;
    overflow: visible;
  }
}

.admin-filter-card.is-collapsed > :not(.admin-card-head) {
  display: none;
}

.admin-filter-card .admin-card-head button {
  width: 34px;
  min-height: 34px;
  border: 1px solid var(--vivo-admin-line);
  border-radius: 6px;
  background: #fff;
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
}

.admin-report-filter,
.admin-product-filter-grid,
.admin-order-filter-grid,
.settings-form,
.detail-form-grid,
.filter-type-form,
.inline-admin-form {
  color: var(--vivo-admin-ink);
}

.admin-report-filter input,
.admin-product-filter-grid input,
.admin-product-filter-grid select,
.admin-order-filter-grid input,
.admin-order-filter-grid select,
.settings-form input,
.settings-form select,
.settings-form textarea,
.detail-form-grid input,
.detail-form-grid select,
.detail-form-grid textarea,
.filter-type-form input,
.filter-type-form select,
.filter-type-form textarea,
.inline-admin-form input,
.inline-admin-form select,
.inline-admin-form textarea,
.admin-table-toolbar input,
.admin-table-toolbar select,
.fake-editor {
  min-height: 38px;
  border: 1px solid #dce4ef;
  border-radius: 6px;
  background: #fff;
  color: var(--vivo-admin-ink);
  box-shadow: none;
}

.admin-report-filter input:focus,
.admin-product-filter-grid input:focus,
.admin-product-filter-grid select:focus,
.admin-order-filter-grid input:focus,
.admin-order-filter-grid select:focus,
.settings-form input:focus,
.settings-form select:focus,
.settings-form textarea:focus,
.detail-form-grid input:focus,
.detail-form-grid select:focus,
.detail-form-grid textarea:focus {
  border-color: #8db7fa;
  outline: 3px solid #e9f1ff;
}

.btn-info,
.admin-new-button,
.admin-primary-button,
.btn-primary,
.btn-green,
.settings-actions button,
.detail-submit-row button {
  border: 1px solid var(--vivo-admin-blue);
  border-radius: 6px;
  background: var(--vivo-admin-blue);
  color: #fff;
  box-shadow: 0 4px 10px rgba(40, 116, 232, .14);
}

.btn-info:hover,
.admin-new-button:hover,
.admin-primary-button:hover,
.btn-primary:hover,
.btn-green:hover,
.settings-actions button:hover,
.detail-submit-row button:hover {
  background: var(--vivo-admin-blue-dark);
  color: #fff;
}

.btn-muted,
.admin-secondary-button,
.toolbar-button,
.admin-table-toolbar button,
.legacy-text-action,
.row-action,
.admin-eye-button,
.admin-row-next,
.currency-footer a,
.currency-footer button {
  border: 1px solid #dce4ef;
  border-radius: 6px;
  background: #fff;
  color: #52627b;
  box-shadow: none;
}

.btn-muted:hover,
.admin-secondary-button:hover,
.toolbar-button:hover,
.admin-table-toolbar button:hover,
.row-action:hover,
.admin-eye-button:hover,
.admin-row-next:hover {
  border-color: #a9c9fb;
  background: #f1f6ff;
  color: var(--vivo-admin-blue);
}

.admin-metric-row {
  gap: 16px;
}

.admin-metric,
.metric-card {
  min-height: 112px;
  border: 1px solid var(--vivo-admin-line);
  border-radius: var(--vivo-admin-radius);
  background: #fff;
  box-shadow: var(--vivo-admin-shadow);
}

.admin-metric:hover,
.metric-card:hover {
  transform: none;
  box-shadow: 0 6px 18px rgba(26, 53, 92, .08);
}

.admin-metric strong,
.metric-value {
  color: var(--vivo-admin-ink);
}

.admin-metric span,
.metric-label,
.metric-change {
  color: var(--vivo-admin-muted);
}

.admin-table-toolbar {
  min-height: 54px;
  border-bottom: 1px solid var(--vivo-admin-line);
  color: var(--vivo-admin-muted);
}

.admin-table-toolbar > div,
.admin-table-toolbar > div > form,
.admin-table-toolbar .inline-form {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.admin-table-toolbar > div > select,
.admin-table-toolbar > div > button,
.admin-table-toolbar .inline-form > select,
.admin-table-toolbar .inline-form > button {
  flex: 0 0 auto;
}

.column-chooser-host { position: relative; }
.column-chooser { position: absolute; top: calc(100% + 8px); left: 0; z-index: 40; display: grid; min-width: 190px; max-height: 280px; gap: 8px; padding: 12px; overflow-y: auto; border: 1px solid var(--vivo-admin-line); border-radius: 6px; background: #fff; box-shadow: 0 12px 28px rgba(26, 53, 92, .16); }
.column-chooser[hidden] { display: none; }
.column-chooser label { display: flex; align-items: center; gap: 8px; margin: 0; color: #52627b; font-size: 12px; white-space: nowrap; }
.column-chooser input { min-height: auto; }
.admin-data-table .column-hidden { display: none; }

.admin-dashboard-page .admin-metric strong,
.admin-metric-row .admin-metric strong {
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: clamp(18px, 1.45vw, 28px);
}

.admin-data-table,
.legacy-admin-table {
  color: var(--vivo-admin-ink);
}

.admin-data-table th,
.legacy-admin-table th {
  background: #fbfcfe;
  color: #687790;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .02em;
}

.admin-data-table td,
.legacy-admin-table td {
  color: #263653;
}

.admin-data-table td a,
.legacy-admin-table td a {
  color: #31588e;
  font-weight: 700;
}

.admin-data-table tbody tr:hover td,
.legacy-admin-table tbody tr:hover td {
  background: #f8fbff;
}

.status-label.active,
.status-pill-admin.green,
.badge-success {
  border: 0;
  background: #e2f8ee;
  color: #0aa267;
}

.status-label.passive,
.status-pill-admin.passive {
  background: #eef2f7;
  color: #748198;
}

.order-status.order-status-complete { background: #dcfce7; color: #15803d; }
.order-status.order-status-pending { background: #dbeafe; color: #1d4ed8; }
.order-status.order-status-cancelled { background: #fee2e2; color: #b91c1c; }
.order-status.order-status-neutral { background: #f1f5f9; color: #475569; }

.order-status,
.status-pill-admin,
.count-badge {
  border-radius: 5px;
}

.product-tabs,
.settings-tabs,
.admin-order-tabs {
  border-bottom-color: var(--vivo-admin-line);
}

.product-tabs a,
.settings-tabs a,
.admin-order-tabs a {
  border-color: var(--vivo-admin-line);
  background: #fff;
  color: var(--vivo-admin-muted);
}

.product-tabs a.active,
.settings-tabs a.active,
.admin-order-tabs a.active {
  border-color: #b5d0fb;
  background: #edf4ff;
  color: var(--vivo-admin-blue);
}

.product-detail-form,
.settings-form {
  border-color: var(--vivo-admin-line);
  border-radius: 0 0 var(--vivo-admin-radius) var(--vivo-admin-radius);
  background: #fff;
}

.detail-read,
.detail-mini-grid div,
.empty-detail-box,
.admin-order-total-box,
.fake-editor-toolbar {
  border-color: var(--vivo-admin-line);
  background: #fbfcfe;
}

.admin-pager,
.pager,
.currency-footer {
  color: var(--vivo-admin-muted);
}

.admin-pager a,
.pager a,
.currency-footer a,
.currency-footer button,
.currency-footer b {
  min-height: 34px;
  border-radius: 6px;
}

.admin-pager span,
.pager span,
.currency-footer b {
  border-radius: 6px;
  background: var(--vivo-admin-blue);
  color: #fff;
}

.legacy-warning,
.admin-notice {
  border: 1px solid #cfe1ff;
  border-left: 4px solid var(--vivo-admin-blue);
  border-radius: 6px;
  background: #f2f7ff;
  color: #41618f;
}

.cache-success {
  border: 1px solid #b9ecd4;
  border-radius: 6px;
  background: #edfbf4;
  color: #08784a;
}

/* Campaigns still carries a small inline legacy block; keep its controls in the shared grid rhythm. */
.campaigns-table-card {
  padding: 0 !important;
}

.campaigns-table-card .legacy-card-title {
  min-height: 60px;
  padding: 0 20px 18px;
}

.campaigns-filter {
  min-height: 70px;
  padding: 14px 20px !important;
  display: flex;
  align-items: center;
  gap: 10px;
}

.campaigns-filter > div {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
}

.campaigns-filter select,
.campaigns-filter input,
.campaigns-filter button {
  min-height: 38px !important;
  border: 1px solid #dce4ef !important;
  border-radius: 6px !important;
  background: #fff !important;
  color: var(--vivo-admin-ink);
}

.campaigns-filter select {
  width: 86px;
}

.campaigns-filter input {
  width: min(360px, 100%);
  min-width: 0 !important;
  padding: 0 12px !important;
}

.campaigns-filter button {
  padding: 0 18px;
  background: var(--vivo-admin-blue) !important;
  border-color: var(--vivo-admin-blue) !important;
  color: #fff !important;
  font-weight: 800;
}

.campaigns-table td {
  background: #fff !important;
}

.campaigns-table td strong {
  color: var(--vivo-admin-ink) !important;
}

.campaigns-table td small {
  color: var(--vivo-admin-muted) !important;
}

/* Keep page-size controls compact and align list actions with the card header. */
body.admin-shell .operations-filter-group > .operations-page-size {
  width: 92px !important;
  min-width: 92px !important;
  max-width: 92px !important;
  flex: 0 0 92px !important;
}

body.admin-shell .campaigns-table-card .legacy-card-title {
  min-height: 58px;
  padding: 0 20px;
  align-items: center;
}

body.admin-shell .campaigns-table-card .campaigns-add-button {
  position: static;
  min-height: 36px;
  margin: 0;
  border-radius: 6px;
  background: var(--vivo-admin-blue);
  padding: 0 16px;
}

body.admin-shell .campaigns-table-card .campaigns-add-button:hover {
  background: #155bd7;
}

body.admin-shell .returns-card-head {
  gap: 20px;
}

body.admin-shell .returns-search-form {
  display: flex;
  align-items: center;
  flex: 1 1 auto;
  justify-content: flex-end;
  gap: 8px;
  min-width: 0;
}

body.admin-shell .returns-search-form input {
  width: min(520px, 100%);
  min-width: 220px;
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid var(--vivo-admin-line);
  border-radius: 6px;
}

body.admin-shell .returns-search-form button {
  flex: 0 0 auto;
  min-height: 38px;
  padding: 0 16px;
  border: 0;
  border-radius: 6px;
  background: var(--vivo-admin-blue);
  color: #fff;
  font-weight: 700;
}

body.admin-shell .admin-rich-editor {
  width: 100%;
  border: 1px solid var(--vivo-admin-line);
  border-radius: 6px;
  background: #fff;
  overflow: hidden;
}

body.admin-shell .admin-rich-editor-toolbar {
  display: flex;
  gap: 4px;
  padding: 8px;
  border-bottom: 1px solid var(--vivo-admin-line);
  background: #f8faff;
}

body.admin-shell .admin-rich-editor-toolbar button {
  min-width: 34px;
  min-height: 30px;
  padding: 0 8px;
  border: 1px solid #d9e2ef;
  border-radius: 4px;
  background: #fff;
  color: var(--vivo-admin-ink);
  cursor: pointer;
}

body.admin-shell .admin-rich-editor-toolbar button:hover {
  border-color: var(--vivo-admin-blue);
  color: var(--vivo-admin-blue);
}

body.admin-shell .admin-rich-editor-surface {
  min-height: 160px;
  padding: 14px;
  outline: none;
  line-height: 1.6;
}

body.admin-shell .admin-rich-editor-surface:focus {
  box-shadow: inset 0 0 0 2px rgba(36, 111, 235, .12);
}

@media (max-width: 680px) {
  body.admin-shell .returns-card-head {
    align-items: stretch;
    flex-direction: column;
    padding: 14px 16px;
  }

  body.admin-shell .returns-search-form {
    justify-content: stretch;
  }

  body.admin-shell .returns-search-form input {
    min-width: 0;
  }
}

@media (max-width: 1100px) {
  .admin-content {
    padding: 22px;
  }

  .admin-dashboard-page,
  .admin-products-page,
  .admin-settings-page {
    padding: 0;
  }

  .admin-metric-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .detail-form-grid,
  .customer-create-form .detail-form-grid {
    gap: 16px;
  }
}

@media (max-width: 640px) {
  .admin-content {
    padding: 16px;
  }

  .admin-page-title {
    font-size: 22px;
  }

  .admin-report-filter,
  .admin-table-toolbar,
  .products-card-title,
  .legacy-card-title,
  .detail-action-row,
  .admin-status-form,
  .currency-footer {
    align-items: stretch;
    flex-direction: column;
    gap: 10px;
  }

  .admin-report-filter input,
  .admin-report-filter button,
  .admin-report-filter a,
  .admin-report-filter {
    max-width: none;
    width: 100%;
  }

  .admin-metric-row {
    grid-template-columns: 1fr;
  }

  .admin-card-head,
  .products-card-title,
  .legacy-card-title {
    padding-left: 16px;
    padding-right: 16px;
  }

  .admin-table-scroll,
  .admin-orders-card .admin-table-scroll,
  .legacy-table-card .admin-table-scroll {
    max-width: 100%;
    overflow-x: auto;
  }

  .settings-form label,
  .settings-form.narrow label,
  .settings-form .checkbox-line {
    width: 100%;
  }

  .campaigns-filter > div {
    align-items: stretch;
    flex-direction: column;
  }

  .campaigns-filter select,
  .campaigns-filter input,
  .campaigns-filter button {
    width: 100%;
  }
}

.admin-login-page {
  box-sizing: border-box;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: #f7f9fc;
  color: var(--vivo-admin-ink);
  font-family: Inter, "Segoe UI", Arial, sans-serif;
}

.admin-login-shell {
  width: min(100%, 420px);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.admin-login-logo {
  display: block;
  width: 64px;
  height: 64px;
  object-fit: contain;
  filter: drop-shadow(0 5px 12px rgba(26, 53, 92, .12));
}

.admin-login-page,
.admin-login-page input,
.admin-login-page button,
.admin-login-page label {
    font-family: Inter, "Segoe UI", Arial, sans-serif;
}

.admin-login-page h1,
.admin-login-page h2,
.admin-login-page strong {
    font-family: Inter, "Segoe UI", Arial, sans-serif;
}

.admin-login-card {
  box-sizing: border-box;
  width: 100%;
  padding: 32px;
  border: 1px solid var(--vivo-admin-line);
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 12px 36px rgba(26, 53, 92, .09);
}

.admin-login-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
  color: var(--vivo-admin-ink);
  font-size: 18px;
}

.admin-login-card h1 {
  margin: 0 0 8px;
  color: var(--vivo-admin-ink);
  font-size: 24px;
}

.admin-login-card p {
  margin: 0 0 24px;
  color: var(--vivo-admin-muted);
  font-size: 13px;
}

.admin-login-card form {
  display: grid;
  gap: 16px;
}

.admin-login-card label:not(.admin-login-check) {
  display: grid;
  gap: 7px;
  color: #52627b;
  font-size: 12px;
  font-weight: 700;
}

.admin-login-card input:not([type="checkbox"]) {
    box-sizing: border-box;
    width: 100%;
    min-height: 42px;
  padding: 0 12px;
  border: 1px solid #dce4ef;
  border-radius: 6px;
  color: var(--vivo-admin-ink);
}

.admin-login-card button,
.admin-login-card .btn-info {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--vivo-admin-blue);
  border-radius: 6px;
  background: var(--vivo-admin-blue);
  color: #fff;
  text-decoration: none;
  font-weight: 800;
}

.admin-login-check {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--vivo-admin-muted);
  font-size: 12px;
}

.admin-login-error {
  color: #c23b4a;
  font-size: 12px;
}

/* Payment and offer screens use their own column geometry. Generic legacy
   widths are intentionally overridden here to prevent merged headers. */
.payment-methods-table {
  min-width: 1040px;
  table-layout: fixed;
}

.payment-methods-table th:nth-child(1),
.payment-methods-table td:nth-child(1) { width: 190px; }
.payment-methods-table th:nth-child(2),
.payment-methods-table td:nth-child(2) { width: auto; }
.payment-methods-table th:nth-child(3),
.payment-methods-table td:nth-child(3) { width: 100px; }
.payment-methods-table th:nth-child(4),
.payment-methods-table td:nth-child(4) { width: 125px; }
.payment-methods-table th:nth-child(5),
.payment-methods-table td:nth-child(5) { width: 185px; }
.payment-methods-table th:nth-child(6),
.payment-methods-table td:nth-child(6) { width: 125px; }
.payment-methods-table th:nth-child(7),
.payment-methods-table td:nth-child(7) { width: 120px; }

.payment-systems-table {
  min-width: 1060px;
  table-layout: fixed;
}

.payment-systems-table th:nth-child(1),
.payment-systems-table td:nth-child(1) { width: 64px; }
.payment-systems-table th:nth-child(2),
.payment-systems-table td:nth-child(2) { width: 190px; }
.payment-systems-table th:nth-child(3),
.payment-systems-table td:nth-child(3) { width: 180px; }
.payment-systems-table th:nth-child(4),
.payment-systems-table td:nth-child(4) { width: auto; }
.payment-systems-table th:nth-child(5),
.payment-systems-table td:nth-child(5),
.payment-systems-table th:nth-child(6),
.payment-systems-table td:nth-child(6) { width: 135px; }
.payment-systems-table th:nth-child(7),
.payment-systems-table td:nth-child(7) { width: 170px; }

.payment-methods-table th,
.payment-systems-table th,
.payment-logs-table th,
.customer-offers-table th {
  white-space: nowrap;
}

.payment-methods-table td,
.payment-systems-table td {
  overflow-wrap: anywhere;
}

.legacy-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.payment-logs-toolbar .inline-form {
  width: 100%;
  display: grid;
  grid-template-columns: 90px auto minmax(220px, 360px) auto;
  gap: 8px;
}

.payment-logs-toolbar input {
  width: 100%;
  padding: 0 12px;
}

.payment-logs-table {
  min-width: 1320px;
  table-layout: fixed;
}

.payment-logs-table th:nth-child(1),
.payment-logs-table td:nth-child(1) { width: 70px; }
.payment-logs-table th:nth-child(2),
.payment-logs-table td:nth-child(2) { width: 190px; }
.payment-logs-table th:nth-child(3),
.payment-logs-table td:nth-child(3) { width: 145px; }
.payment-logs-table th:nth-child(4),
.payment-logs-table td:nth-child(4) { width: 145px; }
.payment-logs-table th:nth-child(5),
.payment-logs-table td:nth-child(5) { width: 125px; }
.payment-logs-table th:nth-child(6),
.payment-logs-table td:nth-child(6) { width: auto; }
.payment-logs-table th:nth-child(7),
.payment-logs-table td:nth-child(7) { width: 100px; }
.payment-logs-table th:nth-child(8),
.payment-logs-table td:nth-child(8) { width: 135px; }

.payment-log-data {
  position: relative;
}

.payment-log-data summary {
  width: 54px;
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  background: #35aede;
  color: #fff;
  cursor: pointer;
  font-weight: 800;
  list-style: none;
}

.payment-log-data summary::-webkit-details-marker { display: none; }
.payment-log-data pre {
  max-width: 520px;
  max-height: 260px;
  margin: 10px 0 0;
  padding: 12px;
  overflow: auto;
  border: 1px solid var(--vivo-admin-line);
  border-radius: 6px;
  background: #f7f9fc;
  color: #263653;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.payment-system-create-card {
  min-height: 165px;
}

.payment-bank-select-form {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  padding: 10px 16px 28px;
}

.payment-bank-select-form label {
  color: #52627b;
  font-size: 12px;
  font-weight: 700;
}

.payment-bank-select-form select {
  width: 100%;
  min-height: 42px;
  padding: 0 12px;
  border: 1px solid #dce4ef;
  border-radius: 6px;
  background: #fff;
}

.payment-bank-select-form .btn-info {
  justify-self: center;
  min-height: 36px;
  margin-top: 8px;
}

.payment-bank-selection {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 16px 18px;
  padding: 12px 14px;
  border: 1px solid #dce4ef;
  border-radius: 6px;
  background: #f8fbff;
}

.payment-bank-selection span { color: var(--vivo-admin-muted); font-size: 12px; }
.payment-bank-selection strong { color: var(--vivo-admin-ink); }
.payment-bank-selection a { margin-left: auto; }

.customer-offers-table {
  min-width: 1180px;
  table-layout: fixed;
}

.customer-offers-table th:nth-child(1),
.customer-offers-table td:nth-child(1) { width: 145px; }
.customer-offers-table th:nth-child(2),
.customer-offers-table td:nth-child(2) { width: 210px; }
.customer-offers-table th:nth-child(3),
.customer-offers-table td:nth-child(3) { width: auto; }
.customer-offers-table th:nth-child(4),
.customer-offers-table td:nth-child(4) { width: 190px; }
.customer-offers-table th:nth-child(5),
.customer-offers-table td:nth-child(5) { width: 165px; }
.customer-offers-table th:nth-child(6),
.customer-offers-table td:nth-child(6) { width: 145px; text-align: right; }
.customer-offers-table th:nth-child(7),
.customer-offers-table td:nth-child(7) { width: 100px; text-align: right; }
.customer-offers-table th:nth-child(8),
.customer-offers-table td:nth-child(8) { width: 100px; text-align: center; }

/* Customer condition list mirrors the compact legacy administration table. */
.customer-conditions-page { position: relative; }
.customer-condition-new {
  float: right;
  min-height: 26px;
  margin: -2px 0 14px;
  padding: 0 10px;
  border-radius: 0;
  background: #9a79df;
  box-shadow: none;
  font-size: 11px;
  line-height: 26px;
}
.customer-condition-new:hover { background: #8663d0; }
.customer-conditions-card { clear: both; }
.customer-conditions-table {
  min-width: 1260px;
  table-layout: fixed;
}
.customer-conditions-table th,
.customer-conditions-table td {
  padding: 10px 12px;
  font-size: 11px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.customer-conditions-table th:nth-child(1),
.customer-conditions-table td:nth-child(1) { width: 60px; text-align: center; }
.customer-conditions-table th:nth-child(2),
.customer-conditions-table td:nth-child(2) { width: 95px; }
.customer-conditions-table th:nth-child(3),
.customer-conditions-table td:nth-child(3) { width: 340px; }
.customer-conditions-table th:nth-child(4),
.customer-conditions-table td:nth-child(4) { width: 125px; }
.customer-conditions-table th:nth-child(5),
.customer-conditions-table td:nth-child(5) { width: 125px; }
.customer-conditions-table th:nth-child(6),
.customer-conditions-table td:nth-child(6) { width: 105px; }
.customer-conditions-table th:nth-child(7),
.customer-conditions-table td:nth-child(7) { width: 170px; }
.customer-conditions-table th:nth-child(8),
.customer-conditions-table td:nth-child(8) { width: 190px; }
.customer-conditions-table th:nth-child(9),
.customer-conditions-table td:nth-child(9) { width: 105px; text-align: center; }
.customer-conditions-table th:nth-child(10),
.customer-conditions-table td:nth-child(10) { width: 105px; text-align: center; }
.customer-conditions-table th:nth-child(11),
.customer-conditions-table td:nth-child(11) { width: 100px; }
.condition-detail-link {
  display: inline-block;
  padding: 5px 9px;
  border: 0 !important;
  border-radius: 2px;
  background: #36acd5;
  color: #fff !important;
  font-size: 10px;
  font-weight: 700 !important;
  text-decoration: none;
}
.condition-detail-link:hover { background: #239bc4; }
.condition-count {
  display: inline-flex;
  min-width: 18px;
  min-height: 18px;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  border-radius: 3px;
  background: #343a40;
  color: #fff;
  font-size: 10px;
  font-weight: 800;
}
.condition-actions { display: inline-flex; align-items: center; gap: 5px; }
.condition-actions form { margin: 0; }
.condition-action {
  display: inline-flex;
  width: 25px;
  height: 24px;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 0;
  border-radius: 2px;
  color: #fff !important;
  cursor: pointer;
  text-decoration: none;
}
.condition-action.danger { background: #df3e5d; }
.condition-action.next { background: #ff9f0a; }
.condition-action:hover { filter: brightness(.92); color: #fff !important; }

.offers-toolbar .offers-search-form {
  display: flex;
  align-items: center;
  gap: 7px;
}

.offers-toolbar .offers-search-form input {
  width: min(280px, 35vw);
  min-height: 34px;
  padding: 0 10px;
}

@media (max-width: 767px) {
  .payment-logs-toolbar .inline-form { grid-template-columns: 1fr; }
  .payment-bank-selection { align-items: flex-start; flex-direction: column; }
  .payment-bank-selection a { margin-left: 0; }
}

/* Integration detail forms use the same spacious language as the rest of Admin. */
.admin-content .netsis-settings-page {
  min-height: calc(100vh - 64px);
  padding: 20px 22px 36px;
}

.admin-content .netsis-card {
  margin-top: 16px;
  padding: 24px;
  border: 1px solid var(--vivo-admin-line);
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--vivo-admin-shadow);
}

.admin-content .netsis-card h1 {
  margin: 0 0 20px;
  color: var(--vivo-admin-ink);
  font-size: 20px;
  font-weight: 800;
}

.admin-content .netsis-form {
  padding: 0;
  border: 0;
}

.admin-content .netsis-tab {
  display: inline-flex;
  margin: 0 0 20px;
  padding: 9px 14px;
  border: 1px solid #cfe0ff;
  border-radius: 7px;
  background: #eaf2ff;
  color: var(--vivo-admin-blue);
  font-size: 12px;
  font-weight: 800;
}

.admin-content .netsis-fields {
  max-width: none;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px 20px;
}

.admin-content .netsis-fields label {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 7px;
  color: var(--vivo-admin-muted);
  font-size: 11px;
  font-weight: 800;
}

.admin-content .netsis-fields input {
  width: 100%;
  min-height: 40px;
  padding: 9px 12px;
  border: 1px solid #dce5f1;
  border-radius: 7px;
  background: #fff;
  color: var(--vivo-admin-ink);
  font: inherit;
  transition: border-color .16s ease, box-shadow .16s ease;
}

.admin-content .netsis-fields input:focus {
  border-color: #8db7ff;
  outline: 0;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, .12);
}

.admin-content .netsis-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--vivo-admin-line);
}

.admin-content .netsis-save,
.admin-content .netsis-test {
  min-height: 38px;
  padding: 9px 15px;
  border: 1px solid transparent;
  border-radius: 7px;
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
}

.admin-content .netsis-save { background: var(--vivo-admin-blue); }
.admin-content .netsis-test { background: #fff; border-color: #cfe0ff; color: var(--vivo-admin-blue); }
.admin-content .netsis-save:hover { background: #1d4ed8; }
.admin-content .netsis-test:hover { background: #f5f9ff; }

@media (max-width: 800px) {
  .admin-content .netsis-settings-page { padding: 16px 14px 28px; }
  .admin-content .netsis-card { padding: 18px; }
  .admin-content .netsis-fields { grid-template-columns: 1fr; }
  .admin-content .netsis-actions { align-items: stretch; flex-direction: column; }
}

/* Reference-aligned admin surface: airy B2B dashboard layout. */
:root {
  --vivo-admin-blue: #2563eb;
  --vivo-admin-blue-dark: #1d4ed8;
  --vivo-admin-ink: #172b4d;
  --vivo-admin-muted: #71809a;
  --vivo-admin-line: #e6ebf3;
  --vivo-admin-soft: #f7f9fc;
  --vivo-admin-shadow: 0 8px 24px rgba(35, 55, 90, .055);
  --vivo-admin-radius: 10px;
}

body.admin-shell {
  grid-template-columns: 250px minmax(0, 1fr);
  grid-template-rows: 64px minmax(calc(100vh - 64px), auto);
  background: #f8fafd;
}

.admin-topbar {
  height: 64px;
  grid-template-columns: 36px 210px minmax(0, 1fr);
  padding: 0 28px;
  border-bottom-color: #edf0f5;
  box-shadow: 0 2px 12px rgba(31, 52, 84, .04);
}

.admin-brand { gap: 10px; font-size: 16px; color: #142c54; }
.admin-brand img { width: 32px; height: 32px; }
.admin-search { width: min(330px, 28vw); min-height: 36px; border-radius: 7px; }
.admin-search input { font-size: 13px; }

.admin-icon-menu {
  top: 64px;
  height: calc(100vh - 64px);
  padding: 16px 16px 0;
  border-right-color: #edf0f5;
  box-shadow: 4px 0 18px rgba(31, 52, 84, .025);
}

.admin-menu-link {
  min-height: 42px;
  gap: 11px;
  padding: 0 14px;
  border-radius: 8px;
  color: #566783;
  font-size: 13px;
  font-weight: 700;
}

.admin-menu-link:hover,
.admin-menu-item:hover > .admin-menu-link,
.admin-menu-link.active {
  background: #eef4ff;
  color: var(--vivo-admin-blue);
}

.admin-content {
  padding: 24px 36px;
}

.admin-products-page,
.admin-dashboard-page,
.admin-product-detail-page { max-width: 1440px; }

.admin-page-heading-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}

.admin-page-heading-row h1 { margin: 0 0 4px; font-size: 22px; }
.admin-page-heading-row p { margin: 0; color: var(--vivo-admin-muted); font-size: 12px; }
.admin-page-actions { display: flex; align-items: center; gap: 10px; }
.admin-page-actions .admin-new-button,
.admin-page-actions .admin-secondary-button { position: static; }

.admin-product-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin: 0 0 20px;
}

.admin-product-metrics article {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 94px;
  padding: 16px;
  border: 1px solid var(--vivo-admin-line);
  border-radius: 10px;
  background: #fff;
  box-shadow: var(--vivo-admin-shadow);
}

.admin-product-metrics .metric-icon {
  width: 42px;
  height: 42px;
  display: inline-grid;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 11px;
  font-size: 19px;
}

.admin-product-metrics .metric-icon.blue { background: #edf3ff; color: #3478ed; }
.admin-product-metrics .metric-icon.green { background: #eaf9f2; color: #10b981; }
.admin-product-metrics .metric-icon.orange { background: #fff4e8; color: #f97316; }
.admin-product-metrics .metric-icon.purple { background: #f4edff; color: #8b5cf6; }
.admin-product-metrics small,
.admin-product-metrics strong,
.admin-product-metrics em { display: block; }
.admin-product-metrics small { color: #71809a; font-size: 11px; }
.admin-product-metrics strong { margin: 2px 0; color: #172b4d; font-size: 21px; line-height: 1.15; }
.admin-product-metrics em { color: #8a98ae; font-size: 10px; font-style: normal; }

.admin-breadcrumb { margin-bottom: 6px; font-size: 12px; color: #8a98ae; }
.admin-page-title,
.admin-products-page > h1,
.admin-detail-card h1 { font-size: 22px; color: #172b4d; }

.admin-filter-card,
.admin-table-card,
.admin-detail-card,
.settings-card,
.currency-card,
.management-card,
.legacy-table-card,
.product-import-card,
.order-detail-card,
.order-lines-card,
.order-status-card {
  border-color: #e6ebf3;
  border-radius: 10px;
  box-shadow: var(--vivo-admin-shadow);
}

.admin-filter-card { margin-top: 20px; margin-bottom: 20px; }
.admin-card-head { min-height: 50px; padding: 0 18px; font-size: 13px; }
.admin-card-head span { font-size: 13px; }

.admin-product-filter-grid,
.admin-order-filter-grid,
.payment-filter-grid {
  gap: 14px 18px;
  padding: 0 18px 20px;
}

.admin-product-filter-grid input,
.admin-product-filter-grid select,
.admin-order-filter-grid input,
.admin-order-filter-grid select,
.payment-filter-grid input,
.payment-filter-grid select,
.admin-content input[type="text"],
.admin-content input[type="email"],
.admin-content input[type="password"],
.admin-content input[type="number"],
.admin-content input[type="date"],
.admin-content input[type="time"],
.admin-content input[type="search"],
.admin-content textarea,
.admin-content select {
  min-height: 36px;
  border-color: #dfe6f0;
  border-radius: 6px;
  color: #263a5b;
  font-size: 12px;
}

.admin-new-button,
.admin-secondary-button,
.btn-info,
.btn-muted,
.toolbar-button,
.row-action,
.admin-eye-button,
.detail-action-row a,
.admin-status-form button,
.detail-submit-row button,
.settings-actions button {
  min-height: 38px;
  border-radius: 7px;
  font-size: 12px;
}

.admin-table-toolbar,
.products-card-title,
.legacy-card-title { min-height: 54px; padding: 0 18px; }
.admin-table-toolbar { font-size: 12px; }
.admin-table-scroll { overflow-x: auto; }
.admin-data-table { min-width: 1040px; }
.admin-data-table th { background: #fbfcfe; color: #71809a; font-size: 11px; font-weight: 800; }
.admin-data-table td { color: #324564; font-size: 12px; }
.admin-data-table tbody tr:hover { background: #fbfdff; }

.admin-product-table th,
.admin-product-table td { padding: 13px 12px; }
.status-label.active { background: #e6f8f1; color: #0d9b6f; }
.status-label.passive { background: #fff1f2; color: #e11d48; }

/* Shared component language for every admin module. */
.admin-content .admin-table-card,
.admin-content .admin-filter-card,
.admin-content .admin-detail-card,
.admin-content .customer-addresses-card,
.admin-content .management-card,
.admin-content .settings-card,
.admin-content .product-import-card,
.admin-content .order-detail-card,
.admin-content .order-lines-card,
.admin-content .order-status-card,
.admin-content .legacy-table-card {
  overflow: hidden;
}

.admin-content .admin-detail-grid,
.admin-content .admin-form-grid,
.admin-content .settings-form,
.admin-content .inline-admin-form,
.admin-content .filter-type-form,
.admin-content .admin-edit-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px 20px;
  padding: 20px;
}

.admin-content .detail-form-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 16px 20px;
}

.admin-content .admin-detail-field,
.admin-content .form-field,
.admin-content .settings-form label,
.admin-content .detail-form-grid label,
.admin-content .admin-edit-grid label {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 7px;
  color: #71809a;
  font-size: 11px;
  font-weight: 800;
}

.admin-content .admin-detail-field strong {
  min-height: 38px;
  display: flex;
  align-items: center;
  padding: 0 12px;
  border: 1px solid #e1e8f1;
  border-radius: 6px;
  background: #fbfcfe;
  color: #263a5b;
  font-size: 12px;
  font-weight: 600;
}

.admin-content .admin-detail-field.wide,
.admin-content .form-field.wide,
.admin-content .settings-form label:has(textarea),
.admin-content .detail-form-grid label:has(textarea),
.admin-content .admin-edit-grid label:has(textarea) {
  grid-column: 1 / -1;
}

.admin-content .admin-form-actions,
.admin-content .detail-submit-row,
.admin-content .settings-actions,
.admin-content .permissions-submit,
.admin-content .admin-detail-actions,
.admin-content .form-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  padding: 0 20px 20px;
}

.admin-content .admin-notice,
.admin-content .alert,
.admin-content .admin-empty-state {
  margin: 14px 20px;
  padding: 14px 16px;
  border: 1px solid #dce8fb;
  border-radius: 8px;
  background: #f5f9ff;
  color: #4c6383;
  font-size: 12px;
}

.admin-content .admin-empty-state {
  border-style: dashed;
  background: #fbfcfe;
  text-align: center;
}

.admin-content .admin-empty-state strong,
.admin-content .admin-empty-state p { display: block; margin: 0 0 4px; }
.admin-content .admin-empty-state strong { color: #263a5b; font-size: 13px; }

.admin-content .admin-table-scroll table { width: 100%; border-collapse: separate; border-spacing: 0; }
.admin-content .admin-data-table tbody tr { border-bottom: 1px solid #eef2f7; }
.admin-content .admin-data-table tbody tr:last-child { border-bottom: 0; }
.admin-content .admin-data-table td:first-child,
.admin-content .admin-data-table th:first-child { padding-left: 18px; }
.admin-content .admin-data-table td:last-child,
.admin-content .admin-data-table th:last-child { padding-right: 18px; }

.admin-content .legacy-table-footer,
.admin-content .currency-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 18px;
  border-top: 1px solid var(--vivo-admin-line);
  color: var(--vivo-admin-muted);
  font-size: 11px;
}

.admin-content .legacy-table-footer nav,
.admin-content .currency-footer nav { display: flex; align-items: center; gap: 6px; }
.admin-content .legacy-table-footer b,
.admin-content .currency-footer b { min-width: 30px; padding: 8px 10px; border-radius: 6px; background: var(--vivo-admin-blue); color: #fff; text-align: center; }

.admin-content .admin-tabs,
.admin-content .product-tabs,
.admin-content .settings-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 6px;
  border-bottom: 1px solid var(--vivo-admin-line);
  background: #fbfcfe;
}

.admin-content .admin-tabs a,
.admin-content .product-tabs a,
.admin-content .settings-tabs a {
  padding: 9px 13px;
  border-radius: 6px;
  color: #71809a;
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
}

.admin-content .admin-tabs a.active,
.admin-content .product-tabs a.active,
.admin-content .settings-tabs a.active {
  background: #eaf2ff;
  color: var(--vivo-admin-blue);
}

.admin-content .admin-checkbox-row,
.admin-content label:has(input[type="checkbox"]) {
  flex-direction: row;
  align-items: center;
  gap: 8px;
}

.admin-content input[type="checkbox"] { width: 16px; min-height: 16px; accent-color: var(--vivo-admin-blue); }

.admin-content .admin-login-card,
.admin-content .login-card,
.admin-content .access-denied-card {
  width: min(440px, 100%);
  margin: 8vh auto;
  padding: 30px;
  border: 1px solid var(--vivo-admin-line);
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--vivo-admin-shadow);
}

.admin-content .admin-login-card form,
.admin-content .login-card form { display: grid; gap: 14px; }

@media (max-width: 800px) {
  .admin-content .admin-detail-grid,
  .admin-content .admin-form-grid,
  .admin-content .settings-form,
  .admin-content .inline-admin-form,
  .admin-content .filter-type-form,
  .admin-content .admin-edit-grid { grid-template-columns: 1fr; }
  .admin-content .detail-form-grid { grid-template-columns: 1fr; }
  .admin-content .detail-form-grid > [class*="span-"] { grid-column: auto; }
  .admin-content .admin-detail-field.wide,
  .admin-content .form-field.wide,
  .admin-content .settings-form label:has(textarea),
  .admin-content .detail-form-grid label:has(textarea),
  .admin-content .admin-edit-grid label:has(textarea) { grid-column: auto; }
  .admin-content .legacy-table-footer,
  .admin-content .currency-footer { align-items: flex-start; flex-direction: column; }
}

@media (max-width: 1100px) {
  body.admin-shell { grid-template-columns: 80px minmax(0, 1fr); }
  .admin-icon-menu { padding-left: 10px; padding-right: 10px; }
  .admin-menu-link { grid-template-columns: 1fr; justify-items: center; padding: 0; }
  .admin-menu-link span, .admin-sidebar-copy { display: none; }
  .admin-content { padding: 20px 22px 32px; }
}

@media (max-width: 767px) {
  body.admin-shell { display: block; }
  .admin-topbar { position: sticky; top: 0; z-index: 200; padding: 0 14px; }
  .admin-topbar-actions { gap: 6px; }
  .admin-search { display: none; }
  .admin-icon-menu { position: fixed; left: 0; top: 64px; width: 226px; transform: translateX(-100%); transition: transform .2s ease; }
  body:not(.admin-menu-collapsed) .admin-icon-menu { transform: translateX(0); }
  body.admin-menu-collapsed .admin-icon-menu { transform: translateX(-100%); }
  .admin-content { padding: 18px 14px 28px; }
  .admin-product-filter-grid { grid-template-columns: 1fr; }
  .admin-page-heading-row { align-items: flex-start; flex-direction: column; }
  .admin-page-actions { width: 100%; }
  .admin-page-actions > * { flex: 1; text-align: center; }
  .admin-product-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
}

/* Normalize the remaining module-specific legacy screens. */
.admin-content .campaigns-table-card,
.admin-content .reports-table-card,
.admin-content .operations-table-card,
.admin-content .integrations-card,
.admin-content .legacy-table-card {
  border: 1px solid var(--vivo-admin-line) !important;
  border-radius: 12px !important;
  background: #fff !important;
  box-shadow: var(--vivo-admin-shadow) !important;
}

.admin-content .campaigns-table td,
.admin-content .reports-table td,
.admin-content .operations-table td {
  background: #fff !important;
  color: var(--vivo-admin-ink) !important;
}

.admin-content .campaigns-table tbody tr:hover td,
.admin-content .reports-table tbody tr:hover td,
.admin-content .operations-table tbody tr:hover td {
  background: #f8fbff !important;
}

.admin-content .campaign-alert,
.admin-content .theme-alert,
.admin-content .currency-alert {
  border: 1px solid #cfe0ff !important;
  border-left: 3px solid var(--vivo-admin-blue) !important;
  border-radius: 7px !important;
  background: #f5f9ff !important;
  color: #4c6383 !important;
}

.admin-content .campaign-action.dark,
.admin-content .report-action.dark,
.admin-content .operations-action-form button {
  background: var(--vivo-admin-blue) !important;
  border-radius: 6px !important;
}

.admin-content .campaign-action.next,
.admin-content .report-action.next {
  background: #fff !important;
  border: 1px solid #cfe0ff !important;
  color: var(--vivo-admin-blue) !important;
}

.admin-content .campaign-action.danger,
.admin-content .report-action.danger,
.admin-content .operations-action-form button.danger,
.admin-content .integration-row-title button[form^="delete-"] {
  background: #fff1f2 !important;
  border: 1px solid #fecdd3 !important;
  color: #be123c !important;
}

.admin-content .integration-create,
.admin-content .integration-row,
.admin-content .integration-empty {
  border-color: var(--vivo-admin-line) !important;
  border-radius: 8px !important;
  background: #fbfcfe !important;
}

.admin-content .integration-row-focused {
  border-color: #9fc0ff !important;
  background: #f5f9ff !important;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, .10) !important;
}

.admin-content .theme-side-tabs nav a.active,
.admin-content .legacy-tabs .active {
  border-color: #cfe0ff !important;
  border-left-color: var(--vivo-admin-blue) !important;
  border-top-color: var(--vivo-admin-blue) !important;
  background: #eaf2ff !important;
  color: var(--vivo-admin-blue) !important;
}

.admin-content .theme-form-field input,
.admin-content .theme-form-field select,
.admin-content .theme-form-field textarea,
.admin-content .theme-color-input input:not(.theme-color-picker),
.admin-content .operations-filter input,
.admin-content .integration-fields input,
.admin-content .integration-fields textarea,
.admin-content .currency-table input {
  border-color: #dce5f1 !important;
  border-radius: 7px !important;
  background: #fff !important;
}

.admin-content .campaign-edit-page .campaign-form,
.admin-content .campaign-edit-page .campaign-child-section,
.admin-content .campaign-edit-page .campaign-raw-fields {
  border: 1px solid var(--vivo-admin-line) !important;
  border-radius: 10px !important;
  background: #fff !important;
  box-shadow: 0 4px 14px rgba(38, 58, 91, .04) !important;
}

.admin-content .campaign-edit-page .campaign-form input,
.admin-content .campaign-edit-page .campaign-form select,
.admin-content .campaign-edit-page .campaign-form textarea {
  min-height: 40px;
  border: 1px solid #dce5f1 !important;
  border-radius: 7px !important;
  background: #fff !important;
  color: var(--vivo-admin-ink) !important;
}

.admin-content .campaign-edit-page .campaign-form button,
.admin-content .campaign-edit-page .campaign-form-actions button,
.admin-content .campaign-edit-page .theme-form-actions button {
  min-height: 38px;
  border-radius: 7px !important;
  background: var(--vivo-admin-blue) !important;
  color: #fff !important;
}

.admin-content .currency-actions button,
.admin-content .currency-actions .currency-danger {
  border-radius: 7px !important;
  background: var(--vivo-admin-blue) !important;
  color: #fff !important;
}

.admin-content .currency-actions .currency-danger {
  background: #fff1f2 !important;
  border: 1px solid #fecdd3 !important;
  color: #be123c !important;
}

.admin-content .theme-form-actions button,
.admin-content .theme-form-actions input[type="submit"] {
  min-height: 38px;
  border: 0 !important;
  border-radius: 7px !important;
  background: var(--vivo-admin-blue) !important;
  color: #fff !important;
  padding: 9px 16px !important;
}

.admin-content .theme-form-actions { display: flex; justify-content: flex-end; gap: 10px; }

.admin-content .admin-page-heading {
  margin: 0 0 18px;
}

.admin-content .admin-page-heading h1 {
  margin: 0 0 5px;
  color: var(--vivo-admin-ink);
  font-size: 22px;
  font-weight: 800;
}

.admin-content .admin-page-heading p {
  margin: 0;
  color: var(--vivo-admin-muted);
  font-size: 12px;
}

.admin-content .admin-reference-table {
  overflow: hidden;
  border: 1px solid var(--vivo-admin-line) !important;
  border-radius: 12px !important;
  background: #fff !important;
  box-shadow: var(--vivo-admin-shadow) !important;
}

.admin-content .admin-reference-table .admin-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 58px;
  padding: 0 18px;
  border-bottom: 1px solid #eef2f7;
}

.admin-content .admin-reference-table .admin-card-header h2 {
  margin: 0 0 3px;
  color: var(--vivo-admin-ink);
  font-size: 14px;
  font-weight: 800;
}

.admin-content .admin-reference-toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px 18px;
  border-bottom: 1px solid #eef2f7;
  background: #fbfcfe;
}

.admin-content .admin-reference-toolbar input,
.admin-content .admin-reference-toolbar select {
  min-height: 38px;
  border: 1px solid #dce5f1 !important;
  border-radius: 7px !important;
  background: #fff !important;
  color: var(--vivo-admin-ink);
}

.admin-content .admin-reference-toolbar input { flex: 1 1 320px; }
.admin-content .admin-reference-toolbar select { width: 110px; }

.admin-content .admin-reference-toolbar .admin-button.primary {
  min-height: 38px;
  border: 0;
  border-radius: 7px;
  background: var(--vivo-admin-blue);
  color: #fff;
}

.admin-content .dedicated-reference-card {
  overflow: hidden;
  border: 1px solid var(--vivo-admin-line) !important;
  border-radius: 12px !important;
  background: #fff !important;
  box-shadow: var(--vivo-admin-shadow) !important;
}

.admin-content .dedicated-reference-card .products-card-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 58px;
  padding: 0 18px;
  border-bottom: 1px solid #eef2f7;
}

.admin-content .dedicated-reference-card .products-card-title h2 {
  margin: 0;
  color: var(--vivo-admin-ink);
  font-size: 14px;
  font-weight: 800;
}

@media (max-width: 700px) {
  .admin-content .admin-reference-toolbar { align-items: stretch; flex-direction: column; }
  .admin-content .admin-reference-toolbar select,
  .admin-content .admin-reference-toolbar input { width: 100%; flex-basis: auto; }
}

/* Customer detail tabs: use one continuous frame so the active tab and
   content panel do not leave doubled or interrupted borders. */
.admin-content .admin-detail-card > .product-tabs {
    position: relative;
    z-index: 1;
    box-sizing: border-box;
    margin: 0;
    padding: 6px 6px 0;
    border: 1px solid var(--vivo-admin-line);
    border-bottom: 0;
    border-radius: 8px 8px 0 0;
    background: #fbfcfe;
}

.admin-content .admin-detail-card > .product-tabs a {
    position: relative;
    margin: 0 2px 0 0;
    border: 1px solid transparent;
    border-bottom: 0;
    border-radius: 6px 6px 0 0;
    background: transparent;
}

.admin-content .admin-detail-card > .product-tabs a.active {
    z-index: 2;
    border-color: var(--vivo-admin-line);
    border-bottom-color: #fff;
    margin-bottom: -1px;
    background: #fff;
}

.admin-content .admin-detail-card > .product-detail-form {
    position: relative;
    z-index: 0;
    border: 1px solid var(--vivo-admin-line);
    border-radius: 0 0 8px 8px;
}

/* Shared list shell: keep customer list pages aligned with the admin grid. */
.admin-content .customer-addresses-page,
.admin-content .linked-customers-page,
.admin-content .customer-permissions-page,
.admin-content .customer-conditions-page {
    width: 100%;
    max-width: none;
    margin: 0;
}

.admin-content .customer-addresses-page .customer-addresses-card,
.admin-content .linked-customers-page .customer-addresses-card,
.admin-content .customer-permissions-page .customer-addresses-card {
    box-sizing: border-box;
    width: 100%;
    padding: 26px 28px 24px;
}

.admin-content .customer-addresses-page .customer-addresses-toolbar,
.admin-content .linked-customers-page .customer-addresses-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 38px;
    margin-bottom: 12px;
}

.customer-addresses-toolbar-left,
.customer-addresses-toolbar-search {
    display: flex;
    align-items: center;
    gap: 8px;
}

.customer-addresses-toolbar-left select,
.customer-addresses-toolbar select {
    flex: 0 0 72px;
    width: 72px;
    min-width: 72px;
}

.customer-addresses-toolbar-search input {
    width: 220px;
    min-height: 38px;
}

.customer-address-create-top {
    position: absolute;
    top: 46px;
    right: 0;
    background: var(--vivo-admin-blue);
    color: #fff;
}

.customer-address-create-top:hover {
    background: var(--vivo-admin-blue-dark);
    color: #fff;
}

/* Customer import page */
.customer-import-page .admin-breadcrumb {
    margin-bottom: 18px;
}

.customer-import-page .product-import-card {
    overflow: hidden;
}

.customer-import-page .products-card-title {
    min-height: 58px;
    display: flex;
    align-items: center;
    padding: 0 20px;
    border-bottom: 1px solid #e1e8f1;
}

.customer-import-page .products-card-title h2 {
    margin: 0;
    color: #172b4d;
    font-size: 16px;
    font-weight: 800;
}

.customer-import-form {
    padding: 22px 20px 0;
    border: 0;
}

.customer-import-form .detail-form-grid {
    gap: 20px;
    align-items: stretch;
}

.customer-import-form .detail-form-grid label {
    gap: 9px;
    color: #263a5b;
    font-size: 12px;
    font-weight: 800;
}

.customer-import-form .detail-form-grid input[type="file"] {
    min-height: 50px;
    padding: 6px 10px;
    border: 1px dashed #a9bddb;
    border-radius: 8px;
    background: #f8fbff;
    color: #71809a;
    font-size: 12px;
}

.customer-import-form .detail-form-grid input[type="file"]::file-selector-button {
    margin-right: 10px;
    padding: 8px 13px;
    border: 0;
    border-radius: 6px;
    background: var(--vivo-admin-blue);
    color: #fff;
    font-weight: 700;
    cursor: pointer;
}

.customer-import-form .import-help {
    min-height: 50px;
    padding: 14px 16px;
    border: 1px solid #dbe6f4;
    border-radius: 8px;
    background: #f8fbff;
    color: #71809a;
    font-size: 12px;
    line-height: 1.6;
}

.customer-import-form .import-help strong {
    margin-bottom: 5px;
    color: #263a5b;
    font-size: 12px;
}

.customer-import-form .import-help p {
    margin: 0;
}

.customer-import-form .detail-actions {
    margin: 22px -20px 0;
    padding: 16px 20px;
    border-top: 1px solid #e8eef6;
    background: #fbfcfe;
}

.customer-import-form .detail-actions button,
.customer-import-form .detail-actions .btn-muted {
    min-height: 40px;
    border-radius: 7px;
    padding: 0 16px;
    font-weight: 800;
}

@media (max-width: 992px) {
    .customer-import-form .detail-form-grid {
        grid-template-columns: 1fr;
    }

    .customer-import-form .span-4,
    .customer-import-form .span-8 {
        grid-column: auto;
    }
}

.address-create-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    margin-right: 7px;
    border: 1px solid currentColor;
    border-radius: 50%;
    font-size: 15px;
    font-weight: 800;
    line-height: 1;
}

.customer-picker-modal[hidden] { display: none; }
.customer-picker-modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: grid;
    place-items: center;
    padding: 24px;
    background: rgba(16, 35, 64, .4);
}
.customer-picker-dialog {
    width: min(620px, 100%);
    max-height: min(680px, calc(100vh - 48px));
    overflow: auto;
    padding: 22px;
    border: 1px solid #dbe5f2;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 18px 50px rgba(20, 45, 80, .22);
}
.customer-picker-header,
.customer-picker-search { display: flex; align-items: center; gap: 10px; }
.customer-picker-header { justify-content: space-between; margin-bottom: 18px; }
.customer-picker-header h2 { margin: 0; color: #12345c; font-size: 18px; }
.customer-picker-close { border: 0; background: transparent; color: #73839a; font-size: 26px; cursor: pointer; }
.customer-picker-search input { flex: 1; min-height: 40px; padding: 0 12px; border: 1px solid #d7e2f1; border-radius: 7px; }
.customer-picker-search button,
.customer-picker-select { border: 0; border-radius: 7px; background: #2864e6; color: #fff; font-weight: 700; }
.customer-picker-search button { min-height: 40px; padding: 0 18px; cursor: pointer; }
.customer-picker-results { display: grid; gap: 8px; margin-top: 16px; }
.customer-picker-result { display: flex; align-items: center; justify-content: space-between; gap: 15px; width: 100%; padding: 13px 14px; border: 1px solid #e1e8f2; border-radius: 8px; background: #fbfcfe; text-align: left; cursor: pointer; }
.customer-picker-result:hover { border-color: #87aef4; background: #f2f7ff; }
.customer-picker-result strong,
.customer-picker-result small { display: block; }
.customer-picker-result strong { color: #17375f; }
.customer-picker-result small { margin-top: 4px; color: #71829a; }
.customer-picker-select { padding: 7px 11px; white-space: nowrap; }
.customer-picker-empty { margin: 12px 0; color: #72829a; text-align: center; }

@media (max-width: 700px) {
    .customer-address-create-top { position: static; margin: 0 0 14px; }
    .admin-content .customer-addresses-page .customer-addresses-toolbar,
    .admin-content .linked-customers-page .customer-addresses-toolbar { align-items: stretch; flex-direction: column; }
    .customer-addresses-toolbar-search { width: 100%; }
    .customer-addresses-toolbar-search input { flex: 1; width: auto; }
}

@media (max-width: 800px) {
  .admin-content .campaigns-table-card,
  .admin-content .reports-table-card,
  .admin-content .operations-table-card,
  .admin-content .integrations-card,
  .admin-content .legacy-table-card { border-radius: 9px !important; }
}

/* Normalize legacy page actions. Older admin pages place .admin-new-button
   directly under the page section; site.css made those buttons absolute,
   which causes visual drift on wide screens and inside tables. */
.admin-content .admin-new-button,
.admin-content .admin-secondary-button {
  position: static;
}

.admin-content .admin-products-page > .admin-breadcrumb,
.admin-content .admin-product-detail-page > .admin-breadcrumb,
.admin-content .admin-order-detail-page > .admin-breadcrumb {
  min-height: 0;
  padding-right: 0;
}

.admin-content .admin-products-page > .admin-new-button,
.admin-content .admin-products-page > .admin-secondary-button,
.admin-content .admin-product-detail-page > .admin-new-button,
.admin-content .admin-product-detail-page > .admin-secondary-button,
.admin-content .admin-order-detail-page > .admin-new-button,
.admin-content .admin-order-detail-page > .admin-secondary-button {
  display: flex;
  width: max-content;
  max-width: 100%;
  align-items: center;
  justify-content: center;
  margin: -2px 0 16px auto;
}

.admin-content .admin-new-button.all-products {
  top: auto;
  right: auto;
  text-transform: none;
}

.admin-content .products-card-title .admin-new-button,
.admin-content .legacy-card-title .admin-new-button,
.admin-content .admin-page-actions .admin-new-button,
.admin-content .admin-detail-actions .admin-new-button,
.admin-content .admin-data-table .admin-new-button,
.admin-content table .admin-new-button {
  width: auto;
  margin: 0;
}

.admin-content table .admin-new-button {
  min-height: 32px;
  padding: 7px 12px;
  box-shadow: none;
}

@media (max-width: 700px) {
  .admin-content .admin-products-page > .admin-new-button,
  .admin-content .admin-products-page > .admin-secondary-button,
  .admin-content .admin-product-detail-page > .admin-new-button,
  .admin-content .admin-product-detail-page > .admin-secondary-button,
  .admin-content .admin-order-detail-page > .admin-new-button,
  .admin-content .admin-order-detail-page > .admin-secondary-button {
    width: 100%;
    margin-left: 0;
  }
}

/* Admin button/form standardization. Keep action buttons predictable across
   legacy pages, details, cards, filters and inline edit rows. */
.admin-content .products-card-title,
.admin-content .legacy-card-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.admin-content .products-card-title h2,
.admin-content .legacy-card-title h2 {
  min-width: 0;
  margin: 0;
}

.admin-content .admin-detail-actions,
.admin-content .detail-action-row,
.admin-content .detail-submit-row,
.admin-content .settings-actions,
.admin-content .settings-crud-form-actions,
.admin-content .theme-form-actions,
.admin-content .campaign-form-actions,
.admin-content .integration-create-actions,
.admin-content .permissions-submit,
.admin-content .admin-form-actions,
.admin-content .form-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
  margin: 0;
  padding: 18px 20px;
  border-top: 1px solid #e8eef6;
}

.admin-content .admin-detail-actions {
  padding: 0;
  margin: 0 0 16px;
  border-top: 0;
}

.admin-content .detail-action-row {
  justify-content: flex-start;
  border-top: 0;
  padding: 14px 0 0;
}

.admin-content .btn-info,
.admin-content .btn-primary,
.admin-content .btn-green,
.admin-content .admin-primary-button,
.admin-content .admin-save-button,
.admin-content .settings-actions button,
.admin-content .settings-crud-form-actions button,
.admin-content .theme-form-actions button,
.admin-content .campaign-form-actions button,
.admin-content .integration-create-actions button,
.admin-content .permissions-submit button,
.admin-content .detail-submit-row button,
.admin-content .admin-form-actions button,
.admin-content .form-actions button,
.admin-content .detail-action-row a,
.admin-content .admin-reference-toolbar .admin-button.primary,
.admin-content .address-search-button,
.admin-content .address-create-button {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid var(--vivo-admin-blue);
  border-radius: 7px;
  background: var(--vivo-admin-blue);
  color: #fff;
  padding: 0 16px;
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: 0 8px 18px rgba(37, 99, 235, .16);
}

.admin-content .btn-info:hover,
.admin-content .btn-primary:hover,
.admin-content .btn-green:hover,
.admin-content .admin-primary-button:hover,
.admin-content .admin-save-button:hover,
.admin-content .settings-actions button:hover,
.admin-content .settings-crud-form-actions button:hover,
.admin-content .theme-form-actions button:hover,
.admin-content .campaign-form-actions button:hover,
.admin-content .integration-create-actions button:hover,
.admin-content .permissions-submit button:hover,
.admin-content .detail-submit-row button:hover,
.admin-content .admin-form-actions button:hover,
.admin-content .form-actions button:hover,
.admin-content .detail-action-row a:hover,
.admin-content .admin-reference-toolbar .admin-button.primary:hover,
.admin-content .address-search-button:hover,
.admin-content .address-create-button:hover {
  background: var(--vivo-admin-blue-dark);
  color: #fff;
  text-decoration: none;
}

.admin-content .btn-muted,
.admin-content .btn-dark,
.admin-content .btn-orange,
.admin-content .admin-secondary-button,
.admin-content .admin-default-button,
.admin-content .smtp-test-button,
.admin-content .toolbar-button,
.admin-content .integration-create-actions a,
.admin-content .settings-crud-form-actions a,
.admin-content .address-columns-button {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid #d6e0ee;
  border-radius: 7px;
  background: #fff;
  color: #34435b;
  padding: 0 16px;
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: none;
}

.admin-content .btn-muted:hover,
.admin-content .btn-dark:hover,
.admin-content .btn-orange:hover,
.admin-content .admin-secondary-button:hover,
.admin-content .admin-default-button:hover,
.admin-content .smtp-test-button:hover,
.admin-content .toolbar-button:hover,
.admin-content .integration-create-actions a:hover,
.admin-content .settings-crud-form-actions a:hover,
.admin-content .address-columns-button:hover {
  border-color: #bcd0eb;
  background: #f8fbff;
  color: var(--vivo-admin-blue);
  text-decoration: none;
}

.admin-content .btn-danger,
.admin-content .currency-danger,
.admin-content .campaign-row-danger,
.admin-content .campaign-action.danger,
.admin-content .condition-action.danger {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #fecdd3;
  border-radius: 7px;
  background: #fff1f2;
  color: #e11d48;
  padding: 0 12px;
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: none;
}

.admin-content .row-delete,
.admin-content .drag-handle,
.admin-content .mini-action,
.admin-content .row-action {
  flex: 0 0 auto;
}

.admin-content .admin-card-head button,
.admin-content .admin-table-toolbar button,
.admin-content .currency-footer button,
.admin-content .admin-table-card nav button {
  min-height: 32px;
  border: 1px solid #d6e0ee;
  border-radius: 7px;
  background: #fff;
  color: #34435b;
  padding: 0 12px;
  font-size: 12px;
  font-weight: 800;
}

.admin-content .customer-condition-new {
  float: none;
  min-height: 38px;
  display: flex;
  width: max-content;
  max-width: 100%;
  align-items: center;
  justify-content: center;
  margin: -2px 0 16px auto;
  border-radius: 7px;
  padding: 0 16px;
  background: var(--vivo-admin-blue);
  font-size: 12px;
  line-height: 1;
  box-shadow: 0 8px 18px rgba(37, 99, 235, .16);
}

.admin-content .customer-conditions-card {
  clear: none;
}

.admin-content .admin-filter-card .btn-info,
.admin-content .admin-filter-card .btn-muted,
.admin-content .admin-card-head + form .btn-info,
.admin-content .admin-card-head + form .btn-muted {
  min-width: 110px;
}

@media (max-width: 700px) {
  .admin-content .admin-detail-actions,
  .admin-content .detail-action-row,
  .admin-content .detail-submit-row,
  .admin-content .settings-actions,
  .admin-content .settings-crud-form-actions,
  .admin-content .theme-form-actions,
  .admin-content .campaign-form-actions,
  .admin-content .integration-create-actions,
  .admin-content .permissions-submit,
  .admin-content .admin-form-actions,
  .admin-content .form-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .admin-content .admin-detail-actions > *,
  .admin-content .detail-action-row > *,
  .admin-content .detail-submit-row > *,
  .admin-content .settings-actions > *,
  .admin-content .settings-crud-form-actions > *,
  .admin-content .theme-form-actions > *,
  .admin-content .campaign-form-actions > *,
  .admin-content .integration-create-actions > *,
  .admin-content .permissions-submit > *,
  .admin-content .admin-form-actions > *,
  .admin-content .form-actions > *,
  .admin-content .customer-condition-new {
    width: 100%;
  }
}

/* Global admin alignment and layering corrections. */
.admin-topbar {
  position: relative;
  z-index: 300;
}

.admin-profile-menu {
  position: relative;
  z-index: 301;
}

.admin-profile-dropdown {
  top: calc(100% + 8px) !important;
  right: 0 !important;
  z-index: 1000 !important;
  min-width: 190px;
  background: #fff;
  border: 1px solid #e5ebf4;
  border-radius: 10px;
  box-shadow: 0 16px 32px rgba(31, 67, 120, .16);
}

.admin-profile-dropdown a {
  color: #334155 !important;
}

.admin-breadcrumb,
.admin-breadcrumb-row .admin-breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.admin-breadcrumb span {
  margin: 0;
}

.admin-menu-link {
  align-items: center;
}

.admin-submenu {
  margin-left: 42px;
}

.admin-submenu a {
  display: block;
  padding: 7px 12px;
  line-height: 1.25;
}

/* Keep the sidebar compact without reducing click targets. */
.admin-menu-link {
  min-height: 40px;
  gap: 9px;
  padding: 0 11px;
}

.admin-submenu {
  margin-left: 28px;
  padding: 1px 0;
  border-left: 0;
}

.admin-submenu a {
  padding: 8px 8px;
  line-height: 1.2;
}

.admin-submenu-branch > .admin-submenu-nested {
  margin-left: 8px !important;
  padding-left: 0 !important;
  border-left: 0 !important;
}

/* Reference-aligned finishing pass: clean spacing, surfaces, and actions. */
.admin-breadcrumb,
.admin-breadcrumb-row .admin-breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.admin-breadcrumb span {
  margin: 0;
}

.admin-content .detail-action-row a,
.admin-content .admin-detail-actions a,
.admin-content .permissions-submit button,
.admin-content .customer-condition-new,
.admin-content .customer-condition-actions a {
  color: #fff !important;
  text-decoration: none;
}

.admin-content .detail-action-row,
.admin-content .admin-detail-actions,
.admin-content .permissions-submit {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.admin-content .detail-action-row a,
.admin-content .admin-detail-actions a,
.admin-content .permissions-submit button {
  min-height: 38px;
  padding: 10px 16px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: var(--vivo-admin-blue);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.2;
}

.admin-content .detail-action-row a:hover,
.admin-content .admin-detail-actions a:hover,
.admin-content .permissions-submit button:hover {
  background: #1d4ed8;
}

.admin-content .customer-addresses-card,
.admin-content .linked-customers-page .customer-addresses-card,
.admin-content .customer-permissions-page .customer-addresses-card,
.admin-content .customer-conditions-card {
  border: 1px solid #e5ebf4;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(31, 67, 120, .06);
}

.admin-content .customer-addresses-card h1,
.admin-content .customer-permissions-page h1,
.admin-content .customer-conditions-card h1 {
  color: #172b4d;
  font-size: 16px;
  font-weight: 800;
}

.admin-content .customer-addresses-table th,
.admin-content .customer-addresses-table td {
  border-color: #edf1f7;
}

.admin-content .customer-addresses-table th {
  background: #fbfcfe;
  color: #71809a;
  font-weight: 800;
}

/* Bring the global customer permissions screen into the main admin visual system. */
.admin-content .customer-permissions-page {
  width: 100%;
  max-width: none;
  margin: 0;
}

.admin-content .customer-permissions-page .customer-addresses-card {
  padding: 26px 28px 28px;
}

.admin-content .customer-permissions-page .customer-addresses-card h1 {
  margin: 0 0 22px;
  color: #172b4d;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: .01em;
}

.admin-content .customer-permissions-page .permissions-warning {
  margin: 0 0 18px;
  padding: 13px 16px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #eff6ff;
  color: #31527d;
  font-size: 12px;
  line-height: 1.5;
}

.admin-content .customer-permissions-page .customer-addresses-table {
  min-width: 0;
  table-layout: fixed;
  font-size: 13px;
}

.admin-content .customer-permissions-page .customer-addresses-table th,
.admin-content .customer-permissions-page .customer-addresses-table td {
  height: 48px;
  padding: 12px 14px;
  border-color: #e5ebf4;
}

.admin-content .customer-permissions-page .customer-addresses-table th {
  background: #f8fafd;
  color: #62728d;
  font-size: 12px;
  font-weight: 800;
}

.admin-content .customer-permissions-page .customer-addresses-table td {
  background: #fff;
  color: #334766;
}

.admin-content .customer-permissions-page .customer-addresses-table th:nth-child(1) { width: 28%; }
.admin-content .customer-permissions-page .customer-addresses-table th:nth-child(2) { width: 52%; }
.admin-content .customer-permissions-page .customer-addresses-table th:nth-child(3) { width: 20%; }

.admin-content .customer-permissions-page .permissions-table input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--vivo-admin-blue);
}

.admin-content .customer-permissions-page .permissions-submit {
  padding: 22px 0 0;
}

.admin-content .customer-permissions-page .permissions-submit button {
  min-height: 40px;
  padding: 0 18px;
  border-radius: 8px;
  box-shadow: 0 8px 18px rgba(37, 99, 235, .16);
}

.admin-content .customer-permissions-page .address-empty {
  height: 76px !important;
  color: #8491a6 !important;
  text-align: center;
}

/* Shared visual language for legacy customer-management list screens. */
.admin-content .customer-addresses-page,
.admin-content .linked-customers-page,
.admin-content .customer-permissions-page {
  color: #172b4d;
}

.admin-content .customer-addresses-page .customer-addresses-card,
.admin-content .linked-customers-page .customer-addresses-card {
  padding: 26px 28px 24px;
}

.admin-content .customer-addresses-page .customer-addresses-card h1,
.admin-content .linked-customers-page .customer-addresses-card h1 {
  margin-bottom: 22px;
  color: #172b4d;
  font-size: 18px;
  font-weight: 800;
}

.admin-content .customer-addresses-page .customer-addresses-toolbar,
.admin-content .linked-customers-page .customer-addresses-toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.admin-content .customer-addresses-page .customer-addresses-toolbar select,
.admin-content .customer-addresses-page .customer-addresses-toolbar input,
.admin-content .linked-customers-page .customer-addresses-toolbar select,
.admin-content .linked-customers-page .customer-addresses-toolbar input {
  min-height: 38px;
  border: 1px solid #d9e2f0;
  border-radius: 7px;
  background: #fff;
  color: #334766;
}

.admin-content .customer-addresses-page .customer-addresses-table,
.admin-content .linked-customers-page .customer-addresses-table {
  font-size: 12px;
}

.admin-content .customer-addresses-page .customer-addresses-table th,
.admin-content .customer-addresses-page .customer-addresses-table td,
.admin-content .linked-customers-page .customer-addresses-table th,
.admin-content .linked-customers-page .customer-addresses-table td {
  border-color: #e5ebf4;
}

.admin-content .customer-addresses-page .customer-addresses-table th,
.admin-content .linked-customers-page .customer-addresses-table th {
  background: #f8fafd;
  color: #62728d;
  font-weight: 800;
}

.admin-content .customer-addresses-page .customer-addresses-table td,
.admin-content .linked-customers-page .customer-addresses-table td {
  background: #fff;
  color: #334766;
}

.admin-content .customer-addresses-page .customer-addresses-table tbody tr:nth-child(odd) td,
.admin-content .linked-customers-page .customer-addresses-table tbody tr:nth-child(odd) td {
  background: #fbfcfe;
}

.admin-content .customer-addresses-page .address-search-button,
.admin-content .customer-addresses-page .address-create-button,
.admin-content .customer-addresses-page .address-columns-button,
.admin-content .linked-customers-page .address-columns-button {
  min-height: 38px;
  border-radius: 7px;
  font-weight: 800;
}

.admin-content .customer-addresses-page .customer-addresses-footer,
.admin-content .linked-customers-page .customer-addresses-footer {
  color: #71809a;
}

/* Customer create form - account/access section has its own stable grid. */
.customer-create-form .customer-form-section:nth-child(4) .detail-form-grid {
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: 20px;
  row-gap: 18px;
  align-items: start;
}

.customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label:nth-child(1),
.customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label:nth-child(2),
.customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label:nth-child(3) {
  grid-column: span 4 !important;
}

.customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label:nth-child(4),
.customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label:nth-child(5),
.customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label:nth-child(6),
.customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label:nth-child(7) {
  grid-column: span 3 !important;
}

.customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label:nth-child(8),
.customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label:nth-child(9) {
  grid-column: span 4 !important;
}

.customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label:nth-child(10),
.customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label:nth-child(11) {
  grid-column: span 2 !important;
}

.customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label:nth-child(12),
.customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label:nth-child(13) {
  grid-column: span 4 !important;
  align-self: center;
}

.customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label small {
  min-height: 16px;
  line-height: 1.35;
}

.customer-create-form .customer-form-section:nth-child(4) .checkbox-line {
  min-height: 22px;
  flex-direction: row;
  align-items: center;
  gap: 9px;
}

.customer-create-form .customer-form-section:nth-child(4) .checkbox-line input {
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
  accent-color: var(--vivo-admin-blue);
}

@media (max-width: 992px) {
  .customer-create-form .customer-form-section:nth-child(4) .detail-form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label {
    grid-column: span 1 !important;
  }
}

@media (max-width: 640px) {
  .customer-create-form .customer-form-section:nth-child(4) .detail-form-grid {
    grid-template-columns: 1fr;
  }
}
.admin-page-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

.admin-page-actions .admin-new-button,
.admin-page-actions .admin-secondary-button,
.admin-form-actions .admin-new-button,
.admin-form-actions .admin-secondary-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    white-space: nowrap;
}

.admin-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    padding: 24px;
}

.admin-form-grid label {
    display: flex;
    flex-direction: column;
    gap: 7px;
    color: #52627d;
    font-size: 13px;
    font-weight: 600;
}

.admin-form-grid input,
.admin-form-grid select,
.admin-form-grid textarea {
    width: 100%;
    min-height: 40px;
    border: 1px solid #d9e2f0;
    border-radius: 7px;
    padding: 9px 12px;
    color: #15294d;
    background: #fff;
}

.admin-form-grid .form-check {
    flex-direction: row;
    align-items: center;
    gap: 9px;
    padding-top: 28px;
}

.admin-form-grid .form-check input { width: 18px; min-height: 18px; }
.admin-form-grid .form-full { grid-column: 1 / -1; }

.admin-form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 0 24px 24px;
}

.customer-user-create-card { min-height: 0 !important; padding: 24px 28px 0; }
.customer-user-create-heading { display: flex; align-items: center; gap: 14px; padding-bottom: 20px; border-bottom: 1px solid #e5ebf3; }
.customer-user-create-icon { display: grid; width: 42px; height: 42px; place-items: center; border-radius: 10px; background: #eaf1ff; color: var(--vivo-admin-blue); font-size: 18px; }
.customer-user-create-heading > div:last-child { display: grid; gap: 3px; }
.customer-user-create-heading > div:last-child > span { color: #6d86ad; font-size: 10px; font-weight: 800; letter-spacing: .12em; }
.customer-user-create-heading h1 { margin: 0; }
.customer-user-create-heading p { margin: 0; color: #71809a; font-size: 13px; }
.customer-user-create-section { padding: 22px 24px 0; }
.customer-user-create-section h2 { margin: 0; color: #172b4d; font-size: 16px; }
.customer-user-create-section p { margin: 5px 0 0; color: #73819a; font-size: 12px; }
.customer-user-create-card .admin-form-grid { padding-top: 16px; }
.customer-user-create-card .admin-form-actions { border-top: 1px solid #e5ebf3; padding-top: 18px; }
.product-required-legend { display: inline-flex; align-items: center; gap: 5px; margin: 6px 0 14px; padding: 6px 10px; border-radius: 5px; background: #fff4f4; color: #65738a; font-size: 12px; }
.product-required-legend strong { color: #dc3545; font-size: 15px; }
.product-detail-form .required-field > span:first-child em { color: #dc3545; font-style: normal; font-weight: 800; }
.product-detail-form .required-field input:invalid,
.product-detail-form .required-field select:invalid { border-color: #f0a3aa; box-shadow: 0 0 0 2px rgba(220, 53, 69, .08); }

/* Sipariş filtresi: durum seçimini öne çıkaran, dengeli 12 kolonlu düzen. */
.admin-orders-page .admin-order-filter-grid { grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 14px; align-items: center; padding: 18px 20px 22px; }
.admin-orders-page .admin-order-filter-grid > input:nth-child(1),
.admin-orders-page .admin-order-filter-grid > input:nth-child(2) { grid-column: span 3; }
.admin-orders-page .admin-order-filter-grid > input:nth-child(3) { grid-column: span 3; }
.admin-orders-page .admin-order-filter-grid > select:nth-child(4) { grid-column: span 3; border: 2px solid #b9cdf4; background: #f7faff; color: #214d9b; font-weight: 700; }
.admin-orders-page .admin-order-filter-grid > select:nth-child(5),
.admin-orders-page .admin-order-filter-grid > select:nth-child(6) { grid-column: span 3; }
.admin-orders-page .admin-order-filter-grid .admin-check-row { grid-column: span 4; min-height: 36px; display: flex; align-items: center; gap: 8px; padding: 0 12px; border: 1px solid #e1e8f2; border-radius: 7px; color: #52627b; font-size: 12px; }
.admin-orders-page .admin-order-filter-grid > a { grid-column: span 3; justify-self: start; padding: 9px 12px; border-radius: 7px; background: #f1f6ff; color: #2563eb; font-size: 12px; font-weight: 700; }
.admin-orders-page .admin-order-filter-grid .filter-buttons { grid-column: span 5; justify-content: flex-end; gap: 8px; }
.admin-orders-page .admin-order-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 14px 18px; border-top: 1px solid #e5ebf3; border-bottom: 1px solid #e5ebf3; background: #fbfcfe; }
.admin-orders-page .admin-order-tabs a { min-height: 34px; padding: 0 14px; border: 1px solid #dbe5f2; border-radius: 999px; background: #fff; color: #53627a; font-size: 12px; font-weight: 700; }
.admin-orders-page .admin-order-tabs a.active { border-color: #2563eb; background: #2563eb; color: #fff; box-shadow: 0 4px 10px rgba(37, 99, 235, .16); }
.admin-orders-page .admin-order-tabs a:nth-child(2) { border-color: #b9cdf4; color: #2563eb; }
.admin-orders-page .admin-order-tabs a:nth-child(3) { border-color: #f2c3c3; color: #c24141; }
@media (max-width: 1100px) {
  .admin-orders-page .admin-order-filter-grid > input,
  .admin-orders-page .admin-order-filter-grid > select,
  .admin-orders-page .admin-order-filter-grid .admin-check-row,
  .admin-orders-page .admin-order-filter-grid > a,
  .admin-orders-page .admin-order-filter-grid .filter-buttons { grid-column: span 6; }
}

.detail-tab-panel[hidden] { display: none !important; }

@media (max-width: 700px) {
    .admin-form-grid { grid-template-columns: 1fr; }
    .admin-form-grid .form-full { grid-column: auto; }
}

/* Customer create/edit form: keep each section on a predictable 4-column rhythm. */
.customer-create-form .customer-form-section .detail-form-grid {
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 18px 20px;
    align-items: start;
}

.customer-create-form .customer-form-section:first-child .detail-form-grid label:first-child {
    grid-column: span 3;
}

.customer-create-form .customer-form-section:nth-child(2) .detail-form-grid label:first-child {
    grid-column: span 6;
}

.customer-create-form .customer-form-section:nth-child(2) .detail-form-grid label:not(:first-child) {
    grid-column: span 3;
}

.customer-create-form .customer-form-section .detail-form-grid label {
    min-width: 0;
}

.customer-create-form .customer-form-section .detail-form-grid label small {
    min-height: 15px;
    line-height: 1.35;
}

@media (max-width: 992px) {
    .customer-create-form .customer-form-section .detail-form-grid,
    .customer-create-form .customer-form-section:nth-child(2) .detail-form-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .customer-create-form .customer-form-section .detail-form-grid > [class*="span-"] {
        grid-column: span 1;
    }

    .customer-create-form .customer-form-section:nth-child(2) .detail-form-grid label:first-child {
        grid-column: 1 / -1;
    }
}

@media (max-width: 640px) {
    .customer-create-form .customer-form-section .detail-form-grid,
    .customer-create-form .customer-form-section:nth-child(2) .detail-form-grid {
        grid-template-columns: 1fr;
    }

    .customer-create-form .customer-form-section .detail-form-grid > [class*="span-"],
    .customer-create-form .customer-form-section:nth-child(2) .detail-form-grid label:first-child {
        grid-column: auto;
    }
}

/* Customer condition row actions: consistent icon-button treatment. */
.admin-content .customer-conditions-table .condition-detail-link {
    display: inline-flex;
    min-height: 32px;
    align-items: center;
    justify-content: center;
    padding: 0 12px;
    border: 1px solid #24a7d5 !important;
    border-radius: 6px;
    background: #2faed5;
    color: #fff !important;
    font-size: 11px;
    font-weight: 700 !important;
    line-height: 1;
    white-space: nowrap;
}

.admin-content .customer-conditions-table .condition-actions {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    min-width: 76px;
}

.admin-content .customer-conditions-table .condition-action,
.admin-content .customer-conditions-table .condition-actions form {
    width: 32px;
    height: 32px;
    min-height: 32px;
}

.admin-content .customer-conditions-table .condition-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 1px solid transparent;
    border-radius: 7px;
    color: #fff !important;
    font-size: 13px;
    line-height: 1;
    box-shadow: 0 2px 5px rgba(28, 52, 84, .10);
}

.admin-content .customer-conditions-table .condition-action.danger {
    border-color: #f5b7c2;
    background: #fff1f3;
    color: #e11d48 !important;
}

.admin-content .customer-conditions-table .condition-action.delete {
    border-color: #f5b7c2;
    background: #fff1f3;
    color: #e11d48 !important;
}

.admin-content .customer-conditions-table .condition-action.next {
    border-color: #f59e0b;
    background: #f59e0b;
    color: #fff !important;
}

.admin-content .customer-conditions-table .condition-action:hover,
.admin-content .customer-conditions-table .condition-detail-link:hover {
    filter: none;
    transform: translateY(-1px);
    box-shadow: 0 4px 9px rgba(28, 52, 84, .16);
}

/* The action cell was narrower than its two icon buttons, so the table's
   ellipsis overflow marker appeared after the orange button. */
.admin-content .customer-conditions-table th:last-child,
.admin-content .customer-conditions-table td:last-child {
    width: 116px;
    overflow: visible;
    text-overflow: clip;
    white-space: nowrap;
}

.admin-content .customer-conditions-table td:last-child .condition-actions {
    min-width: 72px;
    width: max-content;
    overflow: visible;
}

/* Keep page size and column controls in the toolbar's action area, aligned
   with the right edge of the table card. */
.admin-content .customer-conditions-toolbar {
    min-height: 58px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 0 18px;
}

.admin-content .customer-conditions-toolbar > div,
.admin-content .customer-conditions-toolbar > div > form {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0;
}

.admin-content .customer-conditions-toolbar select {
    width: 72px;
}

.admin-content .customer-conditions-toolbar button {
    min-width: 94px;
}

@media (max-width: 640px) {
    .admin-content .customer-conditions-toolbar {
        align-items: stretch;
        justify-content: flex-start;
        padding: 10px 14px;
    }
}

/* Account and access form: avoid the cramped 4/4/2/2 last row and keep the
   advanced settings on a simple, readable rhythm. */
.admin-content .customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label:nth-child(8),
.admin-content .customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label:nth-child(9),
.admin-content .customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label:nth-child(10),
.admin-content .customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label:nth-child(11) {
    grid-column: span 6 !important;
}

.admin-content .customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label:nth-child(12),
.admin-content .customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label:nth-child(13) {
    grid-column: span 6 !important;
}

@media (max-width: 992px) {
    .admin-content .customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label {
        grid-column: span 6 !important;
    }
}

@media (max-width: 640px) {
    .admin-content .customer-create-form .customer-form-section:nth-child(4) .detail-form-grid > label {
        grid-column: 1 / -1 !important;
    }
}

/* Customer detail actions: keep the primary actions together instead of
   allowing legacy button rules to stack them vertically. */
.admin-content .detail-action-row {
    width: 100%;
    box-sizing: border-box;
    display: flex !important;
    flex-direction: row !important;
    align-items: center;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 20px;
    padding: 16px 0 2px;
    border-top: 1px solid var(--vivo-admin-line);
}

.admin-content .detail-action-row a {
    flex: 0 0 auto;
    min-width: 112px;
    min-height: 40px;
    box-sizing: border-box;
    border: 1px solid var(--vivo-admin-blue);
    border-radius: 8px;
    padding: 0 16px;
    background: var(--vivo-admin-blue);
    color: #fff;
    box-shadow: 0 5px 12px rgba(37, 99, 235, .14);
    transition: background .18s ease, border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

.admin-content .detail-action-row a:nth-child(n + 2) {
    border-color: var(--vivo-admin-line);
    background: #fff;
    color: var(--vivo-admin-blue) !important;
    box-shadow: none;
}

.admin-content .detail-action-row a:hover {
    background: #1d4ed8;
    border-color: #1d4ed8;
    color: #fff !important;
    box-shadow: 0 7px 15px rgba(37, 99, 235, .2);
    transform: translateY(-1px);
}

.admin-content .detail-action-row a:nth-child(n + 2):hover {
    background: #edf4ff;
    border-color: #b5d0fb;
    color: var(--vivo-admin-blue) !important;
}

@media (max-width: 700px) {
    .admin-content .detail-action-row {
        align-items: stretch;
        flex-direction: column !important;
    }

    .admin-content .detail-action-row a {
        width: 100%;
    }
}

/* Edit form: the page shell and form shell should not compete with the
   section cards for attention. Keep one clean surface around each section. */
.admin-content .customer-edit-card {
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
}

.admin-content .customer-edit-card > h1 {
    margin: 0 0 18px;
    padding: 0 2px;
}

.admin-content .customer-edit-card .product-detail-form {
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
}

.admin-content .customer-edit-card .customer-form-sections {
    gap: 14px;
}

.admin-content .customer-edit-card .customer-form-section {
    border-color: #e2e9f3;
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 3px 10px rgba(31, 61, 102, .04);
}

.admin-content .customer-edit-card .detail-submit-row {
    min-height: 40px;
    padding: 20px 0 48px;
    border-top: 0;
}

.customer-required-legend {
    margin: -8px 0 16px;
    color: #71809a;
    font-size: 12px;
}

/* Readability pass: the admin UI uses a compact scale, but the smallest
   labels were too light and too close together for daily data entry. */
body.admin-shell {
  color: #243b61;
  font-size: 13px;
  line-height: 1.5;
  font-family: Inter, "Segoe UI", Arial, sans-serif;
}

body.admin-shell :is(input, select, textarea, button) {
  font-family: inherit;
}

body.admin-shell .admin-brand,
body.admin-shell .admin-menu-link,
body.admin-shell .admin-content h1,
body.admin-shell .admin-content h2,
body.admin-shell .admin-content h3,
body.admin-shell .admin-content th,
body.admin-shell .admin-content button {
  font-family: inherit;
}

body.admin-shell .admin-menu-link {
  color: #425777;
  font-size: 14px;
  line-height: 1.35;
}

body.admin-shell .admin-submenu a {
  color: #536887;
  font-size: 13px;
  line-height: 1.45;
}

body.admin-shell .admin-breadcrumb {
  font-size: 13px;
  line-height: 1.5;
}

body.admin-shell .admin-breadcrumb a,
body.admin-shell .admin-breadcrumb span {
  color: #647895;
}

body.admin-shell .admin-breadcrumb a {
  color: #1d5fd1;
  font-weight: 600;
}

body.admin-shell .admin-content input,
body.admin-shell .admin-content select,
body.admin-shell .admin-content textarea {
  color: #243b61;
  font-size: 13px;
  line-height: 1.45;
}

body.admin-shell .admin-content input::placeholder,
body.admin-shell .admin-content textarea::placeholder {
  color: #7a8ba5;
  opacity: 1;
}

body.admin-shell .admin-content label,
body.admin-shell .admin-content .admin-card-head,
body.admin-shell .admin-content .products-card-title,
body.admin-shell .admin-content .legacy-card-title {
  color: #233b61;
}

body.admin-shell .admin-content label {
  line-height: 1.45;
}

body.admin-shell .admin-content .admin-data-table th,
body.admin-shell .admin-content .admin-product-table th {
  color: #4d6384;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .01em;
  line-height: 1.35;
}

body.admin-shell .admin-content .admin-data-table td,
body.admin-shell .admin-content .admin-product-table td {
  color: #2f476b;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.45;
}

body.admin-shell .admin-content .admin-data-table td strong,
body.admin-shell .admin-content .admin-product-table td strong {
  color: #1d3558;
  font-weight: 700;
}

/* Compact reference lists such as Warehouses, Brands and Units. */
body.admin-shell .admin-content > .reference-list-page .reference-filter-form {
  grid-template-columns: minmax(280px, 360px) minmax(220px, 300px) auto;
  align-items: end;
  gap: 14px;
}

body.admin-shell .admin-content > .reference-list-page .reference-filter-form .filter-buttons {
  justify-content: flex-start;
}

body.admin-shell .admin-content > .reference-list-page .reference-data-table {
  width: 100%;
  min-width: 0;
  table-layout: fixed;
}

body.admin-shell .admin-content > .reference-list-page .reference-data-table th,
body.admin-shell .admin-content > .reference-list-page .reference-data-table td {
  padding: 13px 18px;
  vertical-align: middle;
}

body.admin-shell .admin-content > .reference-list-page .reference-data-table th:nth-child(1),
body.admin-shell .admin-content > .reference-list-page .reference-data-table td:nth-child(1) { width: 10%; }

body.admin-shell .admin-content > .reference-list-page .reference-data-table th:nth-child(2),
body.admin-shell .admin-content > .reference-list-page .reference-data-table td:nth-child(2) { width: 18%; }

body.admin-shell .admin-content > .reference-list-page .reference-data-table th:nth-child(3),
body.admin-shell .admin-content > .reference-list-page .reference-data-table td:nth-child(3) { width: 42%; }

body.admin-shell .admin-content > .reference-list-page .reference-data-table th:nth-child(4),
body.admin-shell .admin-content > .reference-list-page .reference-data-table td:nth-child(4) { width: 18%; }

body.admin-shell .admin-content > .reference-list-page .reference-data-table th:nth-child(5),
body.admin-shell .admin-content > .reference-list-page .reference-data-table td:nth-child(5) { width: 12%; }

body.admin-shell .admin-content > .reference-list-page .reference-data-table td:nth-child(3) strong {
  color: #1d4ed8;
  font-weight: 800;
}

body.admin-shell .admin-content > .reference-list-page .reference-actions {
  text-align: right;
}

body.admin-shell .admin-content > .reference-list-page .reference-actions .row-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-width: 94px;
  min-height: 36px;
  border: 1px solid #d7e2f0;
  border-radius: 7px;
  background: #fff;
  color: #304a70;
  font-weight: 800;
  text-decoration: none;
}

@media (max-width: 760px) {
  body.admin-shell .admin-content > .reference-list-page .reference-filter-form {
    grid-template-columns: 1fr;
  }

  body.admin-shell .admin-content > .reference-list-page .reference-data-table {
    min-width: 620px;
  }
}

body.admin-shell .admin-content .products-table-card .admin-product-table th:nth-child(10),
body.admin-shell .admin-content .products-table-card .admin-product-table td:nth-child(10) {
  width: 138px;
  min-width: 138px;
}

body.admin-shell .admin-content .products-table-card .admin-product-table .product-date-cell {
  padding-top: 10px;
  padding-bottom: 10px;
  white-space: nowrap;
}

body.admin-shell .admin-content .products-table-card .product-date-line {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 24px;
  color: #58708f;
  font-size: 11px;
  line-height: 1.2;
}

body.admin-shell .admin-content .products-table-card .product-date-line + .product-date-line {
  margin-top: 3px;
}

body.admin-shell .admin-content .products-table-card .product-date-line i {
  width: 14px;
  color: #2563eb;
  font-size: 12px;
  text-align: center;
}

/* Category tree: replace the dense legacy rows with a calmer, aligned list. */
body.admin-shell .admin-content > .admin-category-tree-page {
  max-width: 1600px;
}

body.admin-shell .admin-content > .admin-category-tree-page .category-tree-card {
  min-height: 0;
  padding-bottom: 20px;
  overflow: hidden;
}

body.admin-shell .admin-content > .admin-category-tree-page .category-tree-tools {
  align-items: center;
  gap: 8px;
  padding: 14px 20px 16px;
  border-bottom: 1px solid #edf1f7;
  background: #fbfcff;
}

body.admin-shell .admin-content > .admin-category-tree-page .category-tree-tools button {
  min-height: 36px;
  border: 1px solid #d7e2f0;
  border-radius: 7px;
  background: #fff;
  color: #304a70;
  font-size: 12px;
  font-weight: 800;
}

body.admin-shell .admin-content > .admin-category-tree-page .category-tree-list {
  gap: 8px;
  padding: 18px 20px 4px;
}

body.admin-shell .admin-content > .admin-category-tree-page .category-tree-row {
  min-height: 52px;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  border: 1px solid #e0e8f3;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 2px 8px rgba(31, 65, 114, .035);
  transition: border-color .15s ease, background-color .15s ease, box-shadow .15s ease;
}

body.admin-shell .admin-content > .admin-category-tree-page .category-tree-row:hover {
  border-color: #b9d2f5;
  background: #fbfdff;
  box-shadow: 0 5px 14px rgba(31, 65, 114, .07);
}

body.admin-shell .admin-content > .admin-category-tree-page .menu-drag {
  display: grid;
  width: 32px;
  height: 32px;
  margin-left: 5px;
  place-items: center;
  border-radius: 7px;
  background: #edf3ff;
  color: #3b82f6;
  font-size: 14px;
}

body.admin-shell .admin-content > .admin-category-tree-page .category-tree-title {
  gap: 10px;
  padding-left: 12px;
  color: #263f65;
  font-size: 13px;
}

body.admin-shell .admin-content > .admin-category-tree-page .category-tree-title strong {
  font-weight: 800;
}

body.admin-shell .admin-content > .admin-category-tree-page .category-tree-actions {
  gap: 7px;
  padding-right: 8px;
}

body.admin-shell .admin-content > .admin-category-tree-page .category-tree-actions .status-label.danger {
  border: 1px solid #f5d59a;
  border-radius: 6px;
  background: #fff8e8;
  color: #9a6700;
  font-size: 11px;
  font-weight: 800;
}

body.admin-shell .admin-content > .admin-category-tree-page .category-tree-actions .row-delete,
body.admin-shell .admin-content > .admin-category-tree-page .category-tree-actions .mini-action,
body.admin-shell .admin-content > .admin-category-tree-page .category-tree-actions .admin-row-next {
  width: 34px;
  height: 34px;
  min-height: 34px;
  margin: 0;
  border: 1px solid #d7e2f0;
  border-radius: 7px;
  box-sizing: border-box;
}

body.admin-shell .admin-content > .admin-category-tree-page .category-tree-actions .row-delete {
  background: #fff;
  color: #2563eb;
}

body.admin-shell .admin-content > .admin-category-tree-page .category-tree-actions .mini-action {
  background: #eef3fb;
  color: #506683;
}

body.admin-shell .admin-content > .admin-category-tree-page .category-tree-actions .admin-row-next {
  background: #fff;
  color: #2563eb;
}

@media (max-width: 780px) {
  body.admin-shell .admin-content > .admin-category-tree-page .category-tree-row {
    grid-template-columns: 36px minmax(0, 1fr);
    padding: 6px 0;
  }

  body.admin-shell .admin-content > .admin-category-tree-page .category-tree-actions {
    grid-column: 2;
    justify-content: flex-start;
    flex-wrap: wrap;
    padding: 4px 10px 0 12px;
  }
}

body.admin-shell .admin-content .admin-table-toolbar,
body.admin-shell .admin-content .admin-page-description,
body.admin-shell .admin-content .admin-dashboard-page p {
  color: #5e7392;
  font-size: 13px;
}

body.admin-shell .admin-content button,
body.admin-shell .admin-content .admin-new-button,
body.admin-shell .admin-content .admin-secondary-button,
body.admin-shell .admin-content .toolbar-button {
  font-size: 13px;
  font-weight: 700;
}

body.admin-shell .admin-content .status-label {
  font-size: 12px;
  line-height: 1.3;
}

/* Price list rows contain text actions and two date columns. Keep the
   compact legacy table from turning the product link into an icon-only box
   and give the metadata columns predictable room. */
body.admin-shell .admin-content .price-lists-page .price-list-table {
  min-width: 1120px;
  table-layout: fixed;
}

body.admin-shell .admin-content .price-lists-page .price-list-table th:nth-child(1),
body.admin-shell .admin-content .price-lists-page .price-list-table td:nth-child(1) { width: 58px; }

body.admin-shell .admin-content .price-lists-page .price-list-table th:nth-child(2),
body.admin-shell .admin-content .price-lists-page .price-list-table td:nth-child(2) { width: 150px; }

body.admin-shell .admin-content .price-lists-page .price-list-table th:nth-child(3),
body.admin-shell .admin-content .price-lists-page .price-list-table td:nth-child(3) { width: 190px; }

body.admin-shell .admin-content .price-lists-page .price-list-table th:nth-child(4),
body.admin-shell .admin-content .price-lists-page .price-list-table td:nth-child(4) { width: 120px; }

body.admin-shell .admin-content .price-lists-page .price-list-table th:nth-child(5),
body.admin-shell .admin-content .price-lists-page .price-list-table td:nth-child(5) { width: 115px; }

body.admin-shell .admin-content .price-lists-page .price-list-table th:nth-child(6),
body.admin-shell .admin-content .price-lists-page .price-list-table td:nth-child(6),
body.admin-shell .admin-content .price-lists-page .price-list-table th:nth-child(7),
body.admin-shell .admin-content .price-lists-page .price-list-table td:nth-child(7) {
  width: 165px;
  white-space: nowrap;
}

body.admin-shell .admin-content .price-lists-page .price-list-table th:nth-child(8),
body.admin-shell .admin-content .price-lists-page .price-list-table td:nth-child(8) { width: 115px; }

body.admin-shell .admin-content .price-lists-page .price-list-table th:last-child,
body.admin-shell .admin-content .price-lists-page .price-list-table td:last-child { width: 112px; }

body.admin-shell .admin-content .price-lists-page .price-products-button {
  width: auto;
  min-width: 72px;
  height: 32px;
  min-height: 32px;
  padding: 0 10px;
  border-radius: 6px;
  white-space: nowrap;
}

body.admin-shell .admin-content .price-list-products-page .products-card-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

body.admin-shell .admin-content .price-list-products-page .products-card-title h2 {
  margin: 0 0 3px;
}

body.admin-shell .admin-content .price-list-products-subtitle {
  display: block;
  color: #71809a;
  font-size: 12px;
}

body.admin-shell .admin-content .price-list-products-table {
  min-width: 820px;
  table-layout: fixed;
}

body.admin-shell .admin-content .price-list-products-table th:nth-child(1),
body.admin-shell .admin-content .price-list-products-table td:nth-child(1) { width: 58px; }

body.admin-shell .admin-content .price-list-products-table th:nth-child(2),
body.admin-shell .admin-content .price-list-products-table td:nth-child(2) { width: 190px; }

body.admin-shell .admin-content .price-list-products-table th:nth-child(4),
body.admin-shell .admin-content .price-list-products-table td:nth-child(4),
body.admin-shell .admin-content .price-list-products-table th:nth-child(5),
body.admin-shell .admin-content .price-list-products-table td:nth-child(5) { width: 110px; }

body.admin-shell .admin-content .price-list-products-table th:nth-child(6),
body.admin-shell .admin-content .price-list-products-table td:nth-child(6) {
  width: 145px;
  text-align: right;
  white-space: nowrap;
}

/* Order status badges need enough contrast and padding for Turkish labels
   such as “Hazırlanıyor” to remain legible in dense tables. */
body.admin-shell .admin-content .order-status,
body.admin-shell .admin-content .status-pill-admin.order-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 92px;
  min-height: 26px;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.2;
  text-align: center;
  white-space: nowrap;
}

body.admin-shell .admin-content .order-status.order-status-pending {
  background: #dbeafe;
  color: #1e40af;
}

@media (max-width: 900px) {
  body.admin-shell .admin-menu-link { font-size: 14px; }
  body.admin-shell .admin-content { padding: 20px 18px 30px; }
}

/* Final contrast and spacing refinements for dense management screens. */
body.admin-shell .admin-content :is(input, select, textarea, button, a):focus-visible {
  outline: 3px solid rgba(37, 99, 235, .24);
  outline-offset: 2px;
}

body.admin-shell .admin-content .admin-filter-card .admin-card-head,
body.admin-shell .admin-content .admin-table-card .products-card-title,
body.admin-shell .admin-content .admin-table-card .legacy-card-title {
  min-height: 58px;
}

body.admin-shell .admin-content .admin-filter-card .admin-card-head span,
body.admin-shell .admin-content .admin-table-card .products-card-title h2,
body.admin-shell .admin-content .admin-table-card .legacy-card-title h2 {
  font-size: 14px;
  font-weight: 800;
  letter-spacing: .01em;
}

body.admin-shell .admin-content .admin-table-toolbar {
  min-height: 58px;
  gap: 12px;
  line-height: 1.45;
}

/* Shared list components: all migrated list screens use one toolbar contract. */
body.admin-shell .unified-list-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

body.admin-shell .unified-list-toolbar .admin-table-toolbar-left,
body.admin-shell .unified-list-toolbar .admin-table-toolbar-search {
  display: flex;
  align-items: center;
  gap: 8px;
}

body.admin-shell .unified-list-toolbar .admin-table-toolbar-search input {
  min-width: 220px;
}

body.admin-shell .unified-pagination a.disabled {
  pointer-events: none;
  opacity: .5;
}

@media (max-width: 700px) {
  body.admin-shell .unified-list-toolbar .admin-table-toolbar-search,
  body.admin-shell .unified-list-toolbar .admin-table-toolbar-search input,
  body.admin-shell .unified-list-toolbar .admin-table-toolbar-search button {
    width: 100%;
  }
}

body.admin-shell .admin-content .admin-table-toolbar select,
body.admin-shell .admin-content .admin-table-toolbar input,
body.admin-shell .admin-content .admin-filter-card input,
body.admin-shell .admin-content .admin-filter-card select {
  min-height: 40px;
}

body.admin-shell .admin-content small,
body.admin-shell .admin-content .text-muted,
body.admin-shell .admin-content .help-text,
body.admin-shell .admin-content .field-hint {
  color: #617593;
  font-size: 12px;
  line-height: 1.5;
}

body.admin-shell .admin-content .admin-data-table th,
body.admin-shell .admin-content .admin-data-table td {
  padding-top: 14px;
  padding-bottom: 14px;
}

/* Customer list has a wider, denser table than the other admin modules. */
body.admin-shell .admin-content .customer-management-table {
  font-size: 13px;
}

body.admin-shell .admin-content .customer-management-table th {
  min-height: 48px;
  color: #40597d;
  font-size: 12px;
  font-weight: 800;
  white-space: normal;
}

body.admin-shell .admin-content .customer-management-table td {
  min-height: 52px;
  color: #294466;
  font-size: 13px;
  font-weight: 500;
  white-space: normal;
}

body.admin-shell .admin-content .customer-management-table td a:not(.mini-action) {
  color: #1d5fd1;
  font-weight: 700;
}

body.admin-shell .admin-content .customer-management-table .mini-action {
  font-size: 14px;
}

body.admin-shell .admin-content .admin-pager,
body.admin-shell .admin-content .pager {
  color: #5e7392;
  font-size: 13px;
}

/* B2B navigation hierarchy: operational work first, administration last. */
body.admin-shell .admin-icon-menu {
  gap: 3px;
  padding-top: 18px;
}

body.admin-shell .admin-menu-section-label {
  margin: 18px 12px 6px;
  padding-top: 12px;
  border-top: 1px solid #edf1f7;
  color: #93a2b8;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .09em;
  line-height: 1.3;
  text-transform: uppercase;
}

body.admin-shell .admin-menu-section-label:first-of-type {
  margin-top: 8px;
  padding-top: 0;
  border-top: 0;
}

body.admin-shell .admin-icon-menu > .admin-menu-item.legacy-return-menu {
  display: none;
}

body.admin-shell .admin-icon-menu > .admin-menu-item > .admin-menu-link {
  min-height: 44px;
  border: 1px solid transparent;
}

body.admin-shell .admin-icon-menu > .admin-menu-item > .admin-menu-link:hover,
body.admin-shell .admin-icon-menu > .admin-menu-item:hover > .admin-menu-link,
body.admin-shell .admin-icon-menu > .admin-menu-item > .admin-menu-link.active {
  border-color: #dce9fb;
  background: #f0f5ff;
}

body.admin-shell .admin-icon-menu .admin-submenu a {
  min-height: 32px;
  display: flex;
  align-items: center;
  border-left: 2px solid transparent;
  line-height: 1.35;
}

body.admin-shell .admin-icon-menu .admin-submenu a:hover,
body.admin-shell .admin-icon-menu .admin-submenu a.active {
  border-left-color: #2563eb;
  background: #f3f7ff;
}

/* General settings has the longest navigation branch; keep it readable and
   independently scrollable without changing the position of other sections. */
body.admin-shell .admin-icon-menu > .general-settings-menu > .admin-submenu {
  max-height: calc(100vh - 250px);
  padding: 6px 4px 8px 10px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #c8d5e8 transparent;
}

body.admin-shell .admin-icon-menu > .general-settings-menu > .admin-submenu > a,
body.admin-shell .admin-icon-menu > .general-settings-menu > .admin-submenu > .admin-submenu-branch > a {
  min-height: 34px;
  padding: 0 10px;
  border-radius: 6px;
  font-size: 12px;
}

body.admin-shell .admin-icon-menu > .general-settings-menu > .admin-submenu > .admin-submenu-branch {
  margin: 2px 0;
}

body.admin-shell .admin-icon-menu > .general-settings-menu > .admin-submenu > .admin-submenu-branch > .admin-submenu-nested {
  margin: 3px 0 5px 10px;
  padding: 3px 0 3px 8px;
  border-left: 1px solid #dce6f3;
}

body.admin-shell .admin-icon-menu > .general-settings-menu > .admin-submenu > .admin-submenu-branch > .admin-submenu-nested a {
  min-height: 30px;
  padding-left: 10px;
  color: #6b7e9e;
  font-size: 11px;
}

body.admin-shell .admin-icon-menu > .general-settings-menu > .admin-menu-link.active {
  border-color: #cfe0ff;
  background: #eef4ff;
  color: #1f5fd2;
}

body.admin-menu-collapsed .admin-menu-section-label {
  display: none;
}

/* B2B dashboard: turn the landing page into an operational command center. */
body.admin-shell .dashboard-modern {
  max-width: 1600px;
}

body.admin-shell .dashboard-quick-actions {
  display: grid;
  grid-template-columns: 1.35fr repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 18px;
  padding: 12px;
  border: 1px solid #e1e9f4;
  border-radius: 12px;
  background: #f8faff;
}

body.admin-shell .dashboard-quick-heading {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 4px 10px;
}

body.admin-shell .dashboard-quick-heading strong {
  color: #1c355e;
  font-size: 13px;
}

body.admin-shell .dashboard-quick-heading span {
  margin-top: 4px;
  color: #8191a9;
  font-size: 11px;
}

body.admin-shell .dashboard-quick-actions > a {
  display: grid;
  grid-template-columns: 30px 1fr;
  align-items: center;
  column-gap: 8px;
  min-width: 0;
  padding: 10px;
  border: 1px solid #e0e8f4;
  border-radius: 9px;
  background: #fff;
  color: #294466;
  text-decoration: none;
  transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

body.admin-shell .dashboard-quick-actions > a:hover {
  border-color: #a9c9fb;
  box-shadow: 0 6px 14px rgba(37, 99, 235, .1);
  transform: translateY(-1px);
}

body.admin-shell .dashboard-quick-actions > a > i {
  grid-row: span 2;
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border-radius: 8px;
  background: #edf4ff;
  color: #2563eb;
  font-size: 15px;
}

body.admin-shell .dashboard-quick-actions > a > span {
  overflow: hidden;
  color: #294466;
  font-size: 12px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.admin-shell .dashboard-quick-actions > a > small {
  overflow: hidden;
  color: #8a9ab0;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.admin-shell .dashboard-secondary-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: -5px 0 20px;
}

body.admin-shell .dashboard-secondary-stats article {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 12px 14px;
  border: 1px solid #e6edf6;
  border-radius: 10px;
  background: #fff;
}

body.admin-shell .secondary-stat-icon {
  display: grid;
  width: 32px;
  height: 32px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 8px;
  background: #eaf1ff;
  color: #2563eb;
}

body.admin-shell .secondary-stat-icon.purple { background: #f2ebff; color: #8b5cf6; }
body.admin-shell .secondary-stat-icon.orange { background: #fff2e5; color: #f97316; }
body.admin-shell .secondary-stat-icon.green { background: #e7faf1; color: #10b981; }
body.admin-shell .dashboard-secondary-stats article > div { min-width: 0; flex: 1; }
body.admin-shell .dashboard-secondary-stats strong,
body.admin-shell .dashboard-secondary-stats span { display: block; }
body.admin-shell .dashboard-secondary-stats strong { color: #1d3558; font-size: 16px; line-height: 1.15; }
body.admin-shell .dashboard-secondary-stats div span { margin-top: 3px; color: #7c8da6; font-size: 11px; }
body.admin-shell .dashboard-secondary-stats article > b,
body.admin-shell .dashboard-secondary-stats article > a { margin-left: auto; color: #2563eb; font-size: 11px; font-weight: 800; text-decoration: none; white-space: nowrap; }
body.admin-shell .dashboard-secondary-stats article > b { color: #5e7392; font-weight: 600; }

@media (max-width: 1200px) {
  body.admin-shell .dashboard-quick-actions { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  body.admin-shell .dashboard-quick-heading { grid-column: 1 / -1; padding: 4px 8px; }
  body.admin-shell .dashboard-secondary-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 700px) {
  body.admin-shell .dashboard-quick-actions,
  body.admin-shell .dashboard-secondary-stats { grid-template-columns: 1fr; }
  body.admin-shell .dashboard-quick-heading { grid-column: auto; }
}

/* Shared page shell for legacy and modern B2B list screens. */
body.admin-shell .customer-addresses-page,
body.admin-shell .customer-conditions-page,
body.admin-shell .customer-list-page,
body.admin-shell .admin-product-detail-page {
  max-width: 1600px;
  margin: 0 auto;
}

body.admin-shell .customer-addresses-page .admin-breadcrumb,
body.admin-shell .customer-conditions-page .admin-breadcrumb,
body.admin-shell .customer-list-page .admin-breadcrumb,
body.admin-shell .admin-product-detail-page .admin-breadcrumb {
  margin-bottom: 18px;
}

body.admin-shell .customer-addresses-page > .customer-address-create-top,
body.admin-shell .customer-conditions-page > .customer-condition-new,
body.admin-shell .admin-product-detail-page > .admin-new-button {
  display: flex;
  width: max-content;
  margin: 0 0 12px auto;
}

body.admin-shell .customer-addresses-page > .customer-address-create-top {
  border-color: #2563eb;
  background: #2563eb;
  color: #fff;
}

body.admin-shell .customer-addresses-page > .customer-address-create-top:hover {
  border-color: #1d4ed8;
  background: #1d4ed8;
  color: #fff;
}

body.admin-shell .customer-addresses-card,
body.admin-shell .customer-conditions-card,
body.admin-shell .customer-permissions-page .customer-addresses-card {
  padding: 0;
  overflow: hidden;
  border: 1px solid #e1e9f4;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(31, 65, 114, .05);
}

body.admin-shell .customer-addresses-card > h1,
body.admin-shell .customer-permissions-page .customer-addresses-card > h1,
body.admin-shell .customer-conditions-card > .products-card-title,
body.admin-shell .customer-conditions-card > .legacy-card-title,
body.admin-shell .customer-conditions-card > .products-card-title {
  display: flex;
  align-items: center;
  min-height: 64px;
  margin: 0;
  padding: 0 20px;
  border-bottom: 1px solid #e8eef6;
  color: #172f57;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: .01em;
}

body.admin-shell .customer-addresses-card > h1 {
  font-family: inherit;
}

body.admin-shell .customer-addresses-toolbar,
body.admin-shell .customer-conditions-card .admin-table-toolbar {
  min-height: 62px;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin: 0;
  padding: 12px 20px;
  border-bottom: 1px solid #edf1f7;
  background: #fbfcff;
}

body.admin-shell .customer-addresses-toolbar-left,
body.admin-shell .customer-addresses-toolbar-search {
  display: flex;
  align-items: center;
  gap: 8px;
}

body.admin-shell .customer-addresses-toolbar select,
body.admin-shell .customer-addresses-toolbar input,
body.admin-shell .customer-addresses-toolbar button,
body.admin-shell .customer-conditions-card .admin-table-toolbar select,
body.admin-shell .customer-conditions-card .admin-table-toolbar button {
  min-height: 40px;
  box-sizing: border-box;
  border: 1px solid #d7e2f0;
  border-radius: 7px;
  background: #fff;
  color: #304a70;
  font-size: 13px;
}

body.admin-shell .customer-addresses-toolbar select,
body.admin-shell .customer-conditions-card .admin-table-toolbar select { padding: 0 10px; }
body.admin-shell .customer-addresses-toolbar input { width: min(250px, 30vw); padding: 0 12px; }
body.admin-shell .customer-addresses-toolbar button { padding: 0 14px; font-weight: 800; }
body.admin-shell .customer-addresses-toolbar .address-search-button { border-color: #2563eb; background: #2563eb; color: #fff; }

body.admin-shell .customer-addresses-scroll,
body.admin-shell .customer-conditions-card .admin-table-scroll {
  overflow-x: auto;
}

body.admin-shell .customer-addresses-table,
body.admin-shell .customer-conditions-table,
body.admin-shell .customer-permissions-page .permissions-table {
  font-family: inherit;
  font-size: 13px;
}

body.admin-shell .customer-addresses-table th,
body.admin-shell .customer-conditions-table th,
body.admin-shell .customer-permissions-page .permissions-table th {
  height: 48px;
  padding: 10px 14px;
  border-color: #e1e9f4;
  background: #f7f9fd;
  color: #40597d;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
  white-space: normal;
}

body.admin-shell .customer-addresses-table td,
body.admin-shell .customer-conditions-table td,
body.admin-shell .customer-permissions-page .permissions-table td {
  min-height: 50px;
  padding: 12px 14px;
  border-color: #e5ebf3;
  background: #fff;
  color: #304a70;
  font-size: 13px;
  line-height: 1.45;
  vertical-align: middle;
}

body.admin-shell .customer-addresses-table tbody tr:hover td,
body.admin-shell .customer-conditions-table tbody tr:hover td,
body.admin-shell .customer-permissions-page .permissions-table tbody tr:hover td {
  background: #f8fbff;
}

body.admin-shell .customer-addresses-table td span:not(.customer-type-badge),
body.admin-shell .customer-addresses-table td a,
body.admin-shell .customer-addresses-table td small {
  font-size: 12px;
}

body.admin-shell .customer-addresses-table td a,
body.admin-shell .customer-conditions-table td a {
  color: #1d5fd1;
  font-weight: 700;
}

body.admin-shell .customer-addresses-footer,
body.admin-shell .customer-conditions-card .admin-pager {
  min-height: 58px;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin: 0;
  padding: 12px 20px;
  border-top: 1px solid #edf1f7;
  color: #617593;
  font-size: 12px;
}

body.admin-shell .customer-addresses-card .permissions-warning,
body.admin-shell .customer-addresses-card .legacy-warning,
body.admin-shell .customer-addresses-card .permissions-warning {
  margin: 16px 20px;
  padding: 12px 14px;
  border: 1px solid #b9d7fb;
  border-radius: 8px;
  background: #eff6ff;
  color: #3b5c82;
  font-size: 12px;
  line-height: 1.5;
}

body.admin-shell .customer-permissions-page .permissions-submit,
body.admin-shell .customer-permissions-page .detail-submit-row {
  display: flex;
  justify-content: flex-end;
  padding: 16px 20px 20px;
  border-top: 1px solid #edf1f7;
}

body.admin-shell .customer-permissions-page .permissions-submit button,
body.admin-shell .customer-permissions-page .detail-submit-row button {
  min-height: 40px;
  padding: 0 18px;
  border: 0;
  border-radius: 8px;
  background: #2563eb;
  color: #fff;
  font-size: 13px;
  font-weight: 800;
}

/* Customer permissions: use the available width for readable permission
   names and keep the checkbox column narrow and centered. */
body.admin-shell .customer-permissions-page .permissions-form {
  display: block;
  padding: 0;
}

body.admin-shell .customer-permissions-page .permissions-form .admin-table-scroll {
  overflow-x: auto;
  margin: 0 20px;
}

body.admin-shell .customer-permissions-page .permissions-table {
  width: 100%;
  min-width: 620px;
  table-layout: fixed;
}

body.admin-shell .customer-permissions-page .permissions-table th,
body.admin-shell .customer-permissions-page .permissions-table td {
  box-sizing: border-box;
}

body.admin-shell .customer-permissions-page .permissions-table th:nth-child(1),
body.admin-shell .customer-permissions-page .permissions-table td:nth-child(1) { width: 24%; }

body.admin-shell .customer-permissions-page .permissions-table th:nth-child(2),
body.admin-shell .customer-permissions-page .permissions-table td:nth-child(2) { width: 61%; }

body.admin-shell .customer-permissions-page .permissions-table th:nth-child(3),
body.admin-shell .customer-permissions-page .permissions-table td:nth-child(3) {
  width: 15%;
  text-align: center;
}

body.admin-shell .customer-permissions-page .permissions-table td:nth-child(1),
body.admin-shell .customer-permissions-page .permissions-table td:nth-child(2) {
  overflow-wrap: anywhere;
}

body.admin-shell .customer-permissions-page .permissions-table input[type="checkbox"] {
  width: 17px;
  height: 17px;
  margin: 0;
  accent-color: #2563eb;
  vertical-align: middle;
}

@media (max-width: 760px) {
  body.admin-shell .customer-permissions-page .permissions-form .admin-table-scroll {
    margin: 0 12px;
  }
}

/* Keep customer-related list screens on one shared layout system. */
body.admin-shell .customer-offers-page,
body.admin-shell .customer-conditions-page,
body.admin-shell .linked-customers-page,
body.admin-shell .customer-addresses-page {
  width: 100%;
  max-width: 1600px;
  box-sizing: border-box;
  margin: 0 auto;
  padding: 28px 22px 80px;
}

body.admin-shell .customer-offers-page .admin-table-card,
body.admin-shell .customer-conditions-page .admin-table-card,
body.admin-shell .linked-customers-page .customer-addresses-card,
body.admin-shell .customer-addresses-page .customer-addresses-card {
  overflow: hidden;
  border: 1px solid #e1e9f4;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(31, 65, 114, .05);
}

body.admin-shell .customer-offers-page .products-card-title,
body.admin-shell .customer-conditions-page .products-card-title,
body.admin-shell .customer-offers-page .legacy-card-title {
  display: flex;
  align-items: center;
  min-height: 64px;
  margin: 0;
  padding: 0 20px;
  border-bottom: 1px solid #e8eef6;
  background: #fff;
}

body.admin-shell .customer-offers-page .products-card-title h2,
body.admin-shell .customer-conditions-page .products-card-title h2,
body.admin-shell .customer-offers-page .legacy-card-title h2 {
  margin: 0;
  color: #172f57;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: .01em;
}

body.admin-shell .customer-offers-page .admin-table-toolbar,
body.admin-shell .customer-conditions-page .admin-table-toolbar {
  min-height: 62px;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin: 0;
  padding: 12px 20px;
  border-bottom: 1px solid #edf1f7;
  background: #fbfcff;
}

body.admin-shell .customer-offers-page .offers-search-form {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
}

body.admin-shell .customer-offers-page .offers-search-form input,
body.admin-shell .customer-offers-page .offers-search-form button {
  min-height: 40px;
  box-sizing: border-box;
  border: 1px solid #d7e2f0;
  border-radius: 7px;
  background: #fff;
  color: #304a70;
  font-size: 13px;
}

body.admin-shell .customer-offers-page .offers-search-form input { width: min(440px, 32vw); padding: 0 12px; }
body.admin-shell .customer-offers-page .offers-search-form button { padding: 0 14px; border-color: #2563eb; background: #2563eb; color: #fff; font-weight: 800; }

body.admin-shell .customer-offers-page .admin-data-table th,
body.admin-shell .customer-conditions-page .admin-data-table th,
body.admin-shell .customer-offers-page .admin-data-table td,
body.admin-shell .customer-conditions-page .admin-data-table td {
  min-height: 48px;
  padding: 12px 14px;
  border-color: #e5ebf3;
  font-size: 13px;
  line-height: 1.45;
}

body.admin-shell .customer-offers-page .admin-data-table th,
body.admin-shell .customer-conditions-page .admin-data-table th {
  background: #f7f9fd;
  color: #40597d;
  font-size: 12px;
  font-weight: 800;
}

body.admin-shell .customer-offers-page .legacy-table-footer,
body.admin-shell .customer-conditions-page .legacy-table-footer,
body.admin-shell .linked-customers-page .customer-addresses-footer,
body.admin-shell .customer-addresses-page .customer-addresses-footer {
  min-height: 58px;
  box-sizing: border-box;
  padding: 12px 20px;
  border-top: 1px solid #edf1f7;
  color: #617593;
  font-size: 12px;
}

@media (max-width: 720px) {
  body.admin-shell .customer-offers-page,
  body.admin-shell .customer-conditions-page,
  body.admin-shell .linked-customers-page,
  body.admin-shell .customer-addresses-page { padding: 18px 10px 50px; }
  body.admin-shell .customer-offers-page .offers-search-form { width: 100%; }
  body.admin-shell .customer-offers-page .offers-search-form input { width: 100%; flex: 1; }
}

/* Final shared defaults for all remaining Admin list and detail screens. */
body.admin-shell .admin-content > .admin-products-page,
body.admin-shell .admin-content > .admin-settings-page,
body.admin-shell .admin-content > .admin-legacy-list-page {
  width: 100%;
  max-width: 1600px;
  box-sizing: border-box;
  margin: 0 auto;
  padding: 28px 22px 80px;
}

body.admin-shell .admin-content > .admin-products-page > .admin-breadcrumb,
body.admin-shell .admin-content > .admin-settings-page > .admin-breadcrumb,
body.admin-shell .admin-content > .admin-legacy-list-page > .admin-breadcrumb {
  margin-bottom: 18px;
}

body.admin-shell .admin-content .admin-table-card,
body.admin-shell .admin-content .admin-detail-card,
body.admin-shell .admin-content .management-card,
body.admin-shell .admin-content .settings-card,
body.admin-shell .admin-content .legacy-table-card {
  border: 1px solid #e1e9f4;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(31, 65, 114, .05);
}

body.admin-shell .admin-content > .admin-products-page .products-card-title,
body.admin-shell .admin-content > .admin-products-page .legacy-card-title,
body.admin-shell .admin-content > .admin-settings-page .products-card-title,
body.admin-shell .admin-content > .admin-legacy-list-page .products-card-title,
body.admin-shell .admin-content > .admin-legacy-list-page .legacy-card-title {
  min-height: 64px;
  box-sizing: border-box;
  padding: 0 20px;
  border-bottom: 1px solid #e8eef6;
  background: #fff;
}

body.admin-shell .admin-content > .admin-products-page .products-card-title h2,
body.admin-shell .admin-content > .admin-products-page .legacy-card-title h2,
body.admin-shell .admin-content > .admin-settings-page .products-card-title h2,
body.admin-shell .admin-content > .admin-legacy-list-page .products-card-title h2,
body.admin-shell .admin-content > .admin-legacy-list-page .legacy-card-title h2 {
  color: #172f57;
  font-size: 15px;
  font-weight: 800;
}

body.admin-shell .admin-content > .admin-products-page .admin-table-toolbar,
body.admin-shell .admin-content > .admin-settings-page .admin-table-toolbar,
body.admin-shell .admin-content > .admin-legacy-list-page .admin-table-toolbar {
  min-height: 62px;
  box-sizing: border-box;
  padding: 12px 20px;
  border-bottom: 1px solid #edf1f7;
  background: #fbfcff;
}

body.admin-shell .admin-content .admin-data-table th {
  background: #f7f9fd;
  color: #40597d;
  font-size: 12px;
  font-weight: 800;
}

body.admin-shell .admin-content .admin-data-table td {
  color: #304a70;
  font-size: 13px;
}

body.admin-shell .admin-content .admin-data-table th,
body.admin-shell .admin-content .admin-data-table td {
  border-color: #e5ebf3;
}

@media (max-width: 720px) {
  body.admin-shell .customer-addresses-toolbar { align-items: stretch; flex-direction: column; }
  body.admin-shell .customer-addresses-toolbar-search { width: 100%; }
  body.admin-shell .customer-addresses-toolbar input { width: 100%; flex: 1; }
  body.admin-shell .customer-addresses-footer,
  body.admin-shell .customer-conditions-card .admin-pager { align-items: flex-start; flex-direction: column; }
}

.customer-required-legend strong,
.required-field em {
    color: #dc3545;
    font-style: normal;
    font-weight: 800;
}

.required-field input:invalid,
.required-field select:invalid,
.required-field textarea:invalid {
    border-color: #d9e2f0;
    box-shadow: none;
}

@media (max-width: 700px) {
    .admin-content .customer-edit-card .detail-submit-row {
        padding-bottom: 32px;
    }
}

@media (max-width: 520px) {
    .admin-login-page {
        align-items: flex-start;
        padding: 24px 16px;
    }

    .admin-login-shell {
        width: 100%;
        max-width: 380px;
        margin-top: 4vh;
    }

    .admin-login-logo {
        width: 56px;
        height: 56px;
    }

    .admin-login-card {
        padding: 24px 20px;
        border-radius: 10px;
    }

    .admin-login-card h1 {
        font-size: 22px;
    }
}

/* Satış elemanı formu genel ayar grid'inden bağımsız tek kolon akışında çalışır. */
.admin-content .settings-form.sales-representative-form {
  display: flex;
  flex-direction: column;
  grid-template-columns: none;
  gap: 16px;
  padding: 0;
}

.admin-content .settings-form.sales-representative-form > .sales-form-section,
.admin-content .settings-form.sales-representative-form > .required-fields-note,
.admin-content .settings-form.sales-representative-form > .settings-actions,
.admin-content .settings-form.sales-representative-form > [asp-validation-summary] {
  width: 100%;
  box-sizing: border-box;
}

/* Last-pass alignment: these rules intentionally come last so legacy page
   overrides cannot change the shared Admin geometry. */
body.admin-shell .admin-content > .admin-products-page,
body.admin-shell .admin-content > .admin-settings-page,
body.admin-shell .admin-content > .admin-legacy-list-page {
  width: 100% !important;
  max-width: 1600px !important;
  box-sizing: border-box !important;
  margin: 0 auto !important;
  padding: 28px 22px 80px !important;
}

body.admin-shell .admin-content > .admin-products-page > .admin-breadcrumb,
body.admin-shell .admin-content > .admin-settings-page > .admin-breadcrumb,
body.admin-shell .admin-content > .admin-legacy-list-page > .admin-breadcrumb {
  min-height: 32px;
  margin-bottom: 18px !important;
  padding-right: 0 !important;
}

body.admin-shell .admin-content > .admin-products-page > .admin-table-card,
body.admin-shell .admin-content > .admin-products-page > .admin-detail-card,
body.admin-shell .admin-content > .admin-settings-page > .admin-table-card,
body.admin-shell .admin-content > .admin-settings-page > .admin-detail-card,
body.admin-shell .admin-content > .admin-legacy-list-page > .admin-table-card {
  border: 1px solid #e1e9f4 !important;
  border-radius: 12px !important;
  box-shadow: 0 8px 22px rgba(31, 65, 114, .05) !important;
}

body.admin-shell .admin-content > .admin-products-page .products-card-title,
body.admin-shell .admin-content > .admin-products-page .legacy-card-title,
body.admin-shell .admin-content > .admin-settings-page .products-card-title,
body.admin-shell .admin-content > .admin-legacy-list-page .products-card-title,
body.admin-shell .admin-content > .admin-legacy-list-page .legacy-card-title {
  min-height: 64px !important;
  box-sizing: border-box;
  padding: 0 20px !important;
  border-bottom: 1px solid #e8eef6 !important;
  background: #fff !important;
}

body.admin-shell .admin-content > .admin-products-page .admin-table-toolbar,
body.admin-shell .admin-content > .admin-settings-page .admin-table-toolbar,
body.admin-shell .admin-content > .admin-legacy-list-page .admin-table-toolbar {
  min-height: 62px !important;
  box-sizing: border-box;
  padding: 12px 20px !important;
  border-bottom: 1px solid #edf1f7 !important;
  background: #fbfcff !important;
}

body.admin-shell .admin-content > .admin-products-page .admin-data-table th,
body.admin-shell .admin-content > .admin-legacy-list-page .admin-data-table th {
  background: #f7f9fd !important;
  color: #40597d !important;
  font-size: 12px !important;
  font-weight: 800 !important;
}

body.admin-shell .admin-content > .customer-addresses-page,
body.admin-shell .admin-content > .linked-customers-page {
  width: 100% !important;
  max-width: 1600px !important;
  box-sizing: border-box !important;
  margin: 0 auto !important;
  padding: 28px 22px 80px !important;
}

body.admin-shell .admin-content > .customer-addresses-page > .customer-addresses-card,
body.admin-shell .admin-content > .linked-customers-page > .customer-addresses-card {
  border: 1px solid #e1e9f4 !important;
  border-radius: 12px !important;
  box-shadow: 0 8px 22px rgba(31, 65, 114, .05) !important;
}

body.admin-shell .admin-content > .customer-addresses-page .customer-addresses-toolbar,
body.admin-shell .admin-content > .linked-customers-page .customer-addresses-toolbar {
  min-height: 62px !important;
  box-sizing: border-box;
  padding: 12px 20px !important;
  border-bottom: 1px solid #edf1f7 !important;
  background: #fbfcff !important;
}

body.admin-shell .admin-content > .customer-addresses-page > .customer-addresses-card,
body.admin-shell .admin-content > .linked-customers-page > .customer-addresses-card {
  padding: 0 !important;
}

body.admin-shell .admin-content > .customer-addresses-page .customer-addresses-card > h1,
body.admin-shell .admin-content > .linked-customers-page .customer-addresses-card > h1 {
  display: flex;
  align-items: center;
  min-height: 64px;
  box-sizing: border-box;
  margin: 0 !important;
  padding: 0 20px !important;
  border-bottom: 1px solid #e8eef6;
  color: #172f57;
  font-size: 15px;
  font-weight: 800;
}

/* One consistent list toolbar for legacy and modern admin tables. */
body.admin-shell .admin-content .unified-list-toolbar,
body.admin-shell .admin-content .list-controls-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 62px;
  padding: 10px 20px;
  border-bottom: 1px solid #e8eef6;
  background: #fbfcff;
}

body.admin-shell .admin-content .list-controls-left,
body.admin-shell .admin-content .list-controls-search {
  display: flex;
  align-items: center;
  gap: 8px;
}

body.admin-shell .admin-content .list-controls-left select,
body.admin-shell .admin-content .list-controls-left button,
body.admin-shell .admin-content .list-controls-search input,
body.admin-shell .admin-content .list-controls-search button,
body.admin-shell .admin-content .unified-list-toolbar select,
body.admin-shell .admin-content .unified-list-toolbar button {
  min-height: 38px;
  box-sizing: border-box;
  border: 1px solid #d5e0ef;
  border-radius: 7px;
  background: #fff;
  color: #294466;
  font-size: 12px;
  font-weight: 700;
}

body.admin-shell .admin-content .list-controls-left select { min-width: 70px; padding: 0 10px; }
body.admin-shell .admin-content .list-controls-left button,
body.admin-shell .admin-content .list-controls-search button { padding: 0 14px; cursor: pointer; }
body.admin-shell .admin-content .list-controls-search input { width: min(280px, 32vw); padding: 0 12px; font-weight: 500; }
body.admin-shell .admin-content .list-controls-search button { border-color: #2563eb; background: #2563eb; color: #fff; }
body.admin-shell .admin-content .list-controls-left button:hover,
body.admin-shell .admin-content .list-controls-search button:hover { filter: brightness(.96); }
body.admin-shell .admin-content .unified-column-chooser { top: calc(100% + 6px); }
body.admin-shell .admin-content tr.list-page-hidden,
body.admin-shell .admin-content tr.list-filter-hidden { display: none; }

@media (max-width: 760px) {
  body.admin-shell .admin-content .unified-list-toolbar,
  body.admin-shell .admin-content .list-controls-toolbar { align-items: stretch; flex-direction: column; }
  body.admin-shell .admin-content .list-controls-left,
  body.admin-shell .admin-content .list-controls-search { width: 100%; }
  body.admin-shell .admin-content .list-controls-search input { width: auto; flex: 1; }
}

body.admin-shell .admin-content > .customer-addresses-page .customer-addresses-toolbar,
body.admin-shell .admin-content > .linked-customers-page .customer-addresses-toolbar {
  margin: 0 !important;
}

body.admin-shell .admin-content > .customer-addresses-page .customer-addresses-table,
body.admin-shell .admin-content > .linked-customers-page .customer-addresses-table {
  width: 100%;
}

/* Common final pass for every admin form card. */
body.admin-shell .admin-content .admin-detail-card,
body.admin-shell .admin-content .settings-card,
body.admin-shell .admin-content .management-card {
  min-height: 0 !important;
  height: auto;
}

/* Payment method form: keep the fields compact and make server-side errors
   impossible to miss after a failed post. */
body.admin-shell .admin-content .payment-method-create-card h1 {
  margin: 0;
  padding: 24px 22px 14px;
}

body.admin-shell .admin-content .payment-method-form {
  min-height: 0;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
  padding: 0 22px 24px;
  gap: 20px 28px;
}

body.admin-shell .admin-content .payment-method-form > .form-required-legend,
body.admin-shell .admin-content .payment-method-form > .form-validation-summary,
body.admin-shell .admin-content .payment-method-form > .payment-content-field,
body.admin-shell .admin-content .payment-method-form > .settings-actions {
  grid-column: 1 / -1;
}

body.admin-shell .admin-content .payment-method-form > .form-required-legend {
  margin: 0;
}

body.admin-shell .admin-content .payment-method-form > label > span:first-child {
  display: inline-flex;
  align-items: center;
  min-height: 16px;
}

body.admin-shell .admin-content .payment-method-form > label > span:first-child em {
  margin-left: 4px;
}

body.admin-shell .admin-content .payment-method-form > .form-validation-summary {
  margin: -8px 0 0;
}

body.admin-shell .admin-content .payment-method-form .field-validation,
body.admin-shell .admin-content .payment-method-form .form-validation-summary {
  color: #c6283d;
  font-size: 12px;
  font-weight: 600;
}

body.admin-shell .admin-content .payment-method-form .form-validation-summary {
  padding: 10px 12px;
  border: 1px solid #f0c7cd;
  border-radius: 7px;
  background: #fff7f8;
}

body.admin-shell .admin-content .payment-method-form .form-validation-summary:empty {
  display: none;
}

body.admin-shell .admin-content .payment-method-form > .settings-actions {
  margin-top: 0;
  padding: 18px 0 0;
  border-top: 1px solid #e8eef6;
}

body.admin-shell .admin-content .payment-method-form .fake-editor {
  width: 100%;
}

body.admin-shell .admin-content .payment-method-form .fake-editor-toolbar {
  min-height: 54px;
  align-content: center;
  padding: 12px 14px;
}

body.admin-shell .admin-content .payment-method-form .fake-editor textarea {
  min-height: 130px;
}

@media (max-width: 760px) {
  body.admin-shell .admin-content .payment-method-form {
    grid-template-columns: 1fr;
  }
}

body.admin-shell .admin-content .required-fields-note {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin: 0 22px 14px;
  padding: 6px 10px;
  border: 1px solid #f4d7da;
  border-radius: 6px;
  background: #fff8f8;
  color: #65738a;
  font-size: 12px;
}

body.admin-shell .admin-content .required-fields-note > span,
body.admin-shell .admin-content .required-fields-note strong { color: #dc3545; font-weight: 800; }

body.admin-shell .admin-content .customer-user-create-section .form-required-legend,
body.admin-shell .admin-content .customer-condition-form .form-required-legend,
body.admin-shell .admin-content .settings-form > .form-required-legend {
  margin-left: 0;
  margin-right: 0;
}

body.admin-shell .admin-content .customer-user-create-section .form-required-legend { margin-top: 12px; }

body.admin-shell .admin-content .detail-submit-row,
body.admin-shell .admin-content .admin-form-actions,
body.admin-shell .admin-content .settings-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

body.admin-shell .admin-content .detail-submit-row button,
body.admin-shell .admin-content .admin-form-actions button,
body.admin-shell .admin-content .settings-actions button,
body.admin-shell .admin-content .admin-form-actions a,
body.admin-shell .admin-content .settings-actions a { min-width: 112px; }

/* Final form polish: compact cards, clear required-field guidance, and a
   consistent three-column rhythm on wide screens. */
body.admin-shell .admin-content > .admin-product-detail-page > .admin-detail-card {
  min-height: 0 !important;
  height: auto !important;
  overflow: hidden;
}

body.admin-shell .admin-content > .admin-product-detail-page > .admin-detail-card > h1 {
  margin: 0;
  padding: 24px 22px 4px;
  color: #172f57;
  font-size: 22px;
  line-height: 1.25;
}

body.admin-shell .admin-content .form-required-legend {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin: 0 22px 14px;
  padding: 6px 10px;
  border: 1px solid #f4d7da;
  border-radius: 6px;
  background: #fff8f8;
  color: #65738a;
  font-size: 12px;
  line-height: 1.3;
}

body.admin-shell .admin-content .form-required-legend strong,
body.admin-shell .admin-content .required-field > span:first-child em,
body.admin-shell .admin-content .required-field > em,
body.admin-shell .admin-content .required-mark {
  color: #dc3545;
  font-style: normal;
  font-weight: 800;
}

body.admin-shell .admin-content > .admin-product-detail-page .product-tabs { margin: 0 22px; }
body.admin-shell .admin-content > .admin-product-detail-page .product-detail-form { padding: 22px; }
body.admin-shell .admin-content > .admin-product-detail-page .detail-form-grid { gap: 18px 20px; }
body.admin-shell .admin-content > .admin-product-detail-page .detail-submit-row {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid #e8eef6;
}

body.admin-shell .admin-content .required-field input:invalid,
body.admin-shell .admin-content .required-field select:invalid,
body.admin-shell .admin-content .required-field textarea:invalid { border-color: #d5e0ef; box-shadow: none; }
body.admin-shell .admin-content .required-field input:focus:invalid,
body.admin-shell .admin-content .required-field select:focus:invalid,
body.admin-shell .admin-content .required-field textarea:focus:invalid {
  border-color: #e58b94;
  box-shadow: 0 0 0 3px rgba(220, 53, 69, .1);
}

@media (max-width: 760px) {
  body.admin-shell .admin-content > .admin-product-detail-page > .admin-detail-card > h1,
  body.admin-shell .admin-content > .admin-product-detail-page .product-detail-form { padding-left: 16px; padding-right: 16px; }
  body.admin-shell .admin-content > .admin-product-detail-page .product-tabs { margin-left: 16px; margin-right: 16px; }
  body.admin-shell .admin-content .form-required-legend { margin-left: 16px; margin-right: 16px; }
}

/* Customer list polish: keep the dense legacy data set readable at desktop
   widths and keep every row action inside its own column. */
body.admin-shell .admin-content > .customer-list-page {
  max-width: none;
  padding: 18px 22px 44px;
}

body.admin-shell .admin-content > .customer-list-page .admin-product-filter-grid {
  grid-template-columns: minmax(240px, 1.35fr) minmax(180px, 1fr) repeat(2, minmax(170px, 1fr));
}

body.admin-shell .admin-content > .customer-list-page .admin-table-scroll {
  overflow-x: auto;
  overflow-y: visible;
  scrollbar-width: thin;
}

body.admin-shell .admin-content > .customer-list-page .customer-management-table {
  width: 100%;
  min-width: 1280px;
  table-layout: fixed;
}

body.admin-shell .admin-content > .customer-list-page .customer-management-table th,
body.admin-shell .admin-content > .customer-list-page .customer-management-table td {
  overflow: hidden;
  text-overflow: ellipsis;
}

body.admin-shell .admin-content > .customer-list-page .customer-management-table th:nth-child(1),
body.admin-shell .admin-content > .customer-list-page .customer-management-table td:nth-child(1) { width: 112px; }
body.admin-shell .admin-content > .customer-list-page .customer-management-table th:nth-child(2),
body.admin-shell .admin-content > .customer-list-page .customer-management-table td:nth-child(2) { width: 150px; }
body.admin-shell .admin-content > .customer-list-page .customer-management-table th:nth-child(3),
body.admin-shell .admin-content > .customer-list-page .customer-management-table td:nth-child(3) { width: 145px; }
body.admin-shell .admin-content > .customer-list-page .customer-management-table th:nth-child(4),
body.admin-shell .admin-content > .customer-list-page .customer-management-table td:nth-child(4) { width: 105px; }
body.admin-shell .admin-content > .customer-list-page .customer-management-table th:nth-child(5),
body.admin-shell .admin-content > .customer-list-page .customer-management-table td:nth-child(5) { width: 170px; }
body.admin-shell .admin-content > .customer-list-page .customer-management-table th:nth-child(6),
body.admin-shell .admin-content > .customer-list-page .customer-management-table td:nth-child(6) { width: 130px; }
body.admin-shell .admin-content > .customer-list-page .customer-management-table th:nth-child(7),
body.admin-shell .admin-content > .customer-list-page .customer-management-table td:nth-child(7) { width: 105px; }
body.admin-shell .admin-content > .customer-list-page .customer-management-table th:nth-child(8),
body.admin-shell .admin-content > .customer-list-page .customer-management-table td:nth-child(8) { width: 110px; }
body.admin-shell .admin-content > .customer-list-page .customer-management-table th:nth-child(9),
body.admin-shell .admin-content > .customer-list-page .customer-management-table td:nth-child(9) { width: 115px; }

body.admin-shell .admin-content > .customer-list-page .customer-management-table th:last-child,
body.admin-shell .admin-content > .customer-list-page .customer-management-table td:last-child {
  width: 190px;
}

body.admin-shell .admin-content > .customer-list-page .customer-management-table td.row-actions {
  width: 190px;
  padding: 9px 12px;
  white-space: normal;
}

body.admin-shell .admin-content > .customer-list-page .customer-management-table .row-actions {
  display: grid;
  grid-template-columns: repeat(4, 30px);
  justify-content: end;
  gap: 5px;
}

body.admin-shell .admin-content > .customer-list-page .customer-management-table .mini-action,
body.admin-shell .admin-content > .customer-list-page .customer-management-table .inline-form button.mini-action.danger {
  width: 30px;
  min-width: 30px;
  height: 30px;
  min-height: 30px;
  border-radius: 6px;
}

body.admin-shell .admin-content > .customer-list-page .customer-management-table td:nth-child(5) {
  overflow-wrap: anywhere;
}

@media (max-width: 900px) {
  body.admin-shell .admin-content > .customer-list-page {
    padding: 14px 12px 36px;
  }

  body.admin-shell .admin-content > .customer-list-page .admin-product-filter-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  body.admin-shell .admin-content > .customer-list-page .admin-product-filter-grid {
    grid-template-columns: 1fr;
  }
}

/* Linked customer pagination: use a clear blue footer treatment. */
body.admin-shell .admin-content > .linked-customers-page .customer-addresses-footer .admin-pager {
  margin: 0;
  padding: 7px 9px;
  border-radius: 8px;
  border: 1px solid #e3eaf4;
  background: #f8fafd;
  color: #62728d;
}

body.admin-shell .admin-content > .linked-customers-page .customer-addresses-footer .admin-pager a,
body.admin-shell .admin-content > .linked-customers-page .customer-addresses-footer .admin-pager span {
  min-width: 34px;
  min-height: 30px;
  border: 1px solid #d8e2f0;
  border-radius: 6px;
  background: transparent;
  color: #4d6385;
}

body.admin-shell .admin-content > .linked-customers-page .customer-addresses-footer .admin-pager span:not(.disabled) {
  border-color: #2563eb;
  background: #2563eb;
  color: #fff;
  font-weight: 800;
}

body.admin-shell .admin-content > .linked-customers-page .customer-addresses-footer .admin-pager span.disabled {
  opacity: .58;
}

/* Keep every admin search action on the same visual contract. */
body.admin-shell .admin-content :is(.list-search-button, .address-search-button, .admin-table-toolbar button[type="submit"]) {
  min-height: 40px;
  border: 1px solid #2563eb;
  border-radius: 7px;
  background: #2563eb;
  color: #fff;
  padding: 0 16px;
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
  box-shadow: 0 8px 18px rgba(37, 99, 235, .16);
  transition: background-color .16s ease, border-color .16s ease, box-shadow .16s ease;
}

body.admin-shell .admin-content :is(.list-search-button, .address-search-button, .admin-table-toolbar button[type="submit"]):hover {
  border-color: #1d4ed8;
  background: #1d4ed8;
  color: #fff;
  box-shadow: 0 8px 18px rgba(29, 78, 216, .22);
}

body.admin-shell .admin-content :is(.list-search-button, .address-search-button, .admin-table-toolbar button[type="submit"]):disabled {
  border-color: #93b4f5;
  background: #93b4f5;
  cursor: not-allowed;
  box-shadow: none;
}
