:root {
  --ix-black: #080a0c;
  --ix-surface: #111619;
  --ix-raised: #171e23;
  --ix-line: #2c3a42;
  --ix-line-soft: #1f2a30;
  --ix-paper: #e6eef2;
  --ix-muted: #8399a5;
  --ix-safelight: #35c8f0;
  --ix-safelight-hot: #5ad8fb;
  --ix-safelight-soft: rgba(53, 200, 240, 0.13);
  --ix-amber: #ffab4d;
  --ix-prism: linear-gradient(90deg, #ff4b28, #ffab4d, #6ee7a0, #5ab9ff, #a78bfa);
  --ix-radius: 3px;

  --bs-primary: #35c8f0;
  --bs-primary-rgb: 53, 200, 240;
  --bs-body-bg: #0c0a09;
  --bs-body-color: #f4ece1;
}

body {
  background-color: var(--ix-black);
  background-image:
    radial-gradient(120% 70% at 50% -10%, rgba(53, 200, 240, 0.10) 0%, transparent 60%),
    radial-gradient(90% 60% at 100% 0%, rgba(53, 200, 240, 0.05) 0%, transparent 55%);
  background-attachment: fixed;
  color: var(--ix-paper);
  font-family: Chivo, "Helvetica Neue", sans-serif;
  font-size: 1.02rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  position: relative;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.32;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)' opacity='0.5'/%3E%3C/svg%3E");
}

h1, h2, h3, .display-5, .navbar-brand {
  font-family: "Instrument Serif", Georgia, serif;
  font-weight: 400;
  letter-spacing: -0.01em;
  color: var(--ix-paper);
}

h1, .display-5 { font-size: clamp(2.8rem, 6vw, 4.6rem); line-height: 0.98; }
h2 { font-size: clamp(1.7rem, 3vw, 2.4rem); line-height: 1.1; }
h3 { font-size: 1.5rem; }

h4, h5, h6, .footer-title, .card-title {
  font-family: Chivo, sans-serif;
  font-weight: 600;
  letter-spacing: 0.01em;
}

p, .lead { max-width: 64ch; }
.lead { font-size: 1.08rem; color: var(--ix-muted); font-weight: 300; }
.text-white-50, .text-muted { color: var(--ix-muted) !important; }

a { color: var(--ix-paper); text-decoration-color: var(--ix-line); text-underline-offset: 4px; }
a:hover { color: var(--ix-safelight); }

:focus-visible { outline: 2px solid var(--ix-safelight); outline-offset: 3px; }

.navbar.bg-dark {
  background-color: rgba(12, 10, 9, 0.88) !important;
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--ix-line-soft);
  padding-block: 0.8rem;
}

.navbar-brand { width: auto; height: 34px; margin-right: 1.5rem; }

.navbar-dark .navbar-nav .nav-link {
  color: var(--ix-muted);
  font-size: 0.82rem;
  letter-spacing: 0.12em;
  text-transform: lowercase;
  padding-inline: 0.9rem;
  position: relative;
}

.navbar-dark .navbar-nav .nav-link::after {
  content: "";
  position: absolute;
  left: 0.9rem; right: 0.9rem; bottom: 0.2rem;
  height: 1px;
  background: var(--ix-safelight);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}

.navbar-dark .navbar-nav .nav-link:hover { color: var(--ix-paper); }
.navbar-dark .navbar-nav .nav-link:hover::after,
.navbar-dark .navbar-nav .nav-link.active::after { transform: scaleX(1); }
.navbar-dark .navbar-nav .nav-link.active { color: var(--ix-paper); }

header.bg-dark { background-color: transparent !important; }

.btn {
  font-family: Chivo, sans-serif;
  font-weight: 600;
  font-size: 0.88rem;
  letter-spacing: 0.06em;
  border-radius: var(--ix-radius);
  padding: 0.75rem 1.5rem;
  transition: transform 0.18s ease, background-color 0.18s ease, box-shadow 0.18s ease;
}

.btn-primary {
  background-color: var(--ix-safelight);
  border-color: var(--ix-safelight);
  color: #04161c;
  box-shadow: 0 0 0 0 var(--ix-safelight-soft);
}

.btn-primary:hover, .btn-primary:focus-visible {
  background-color: var(--ix-safelight-hot);
  border-color: var(--ix-safelight-hot);
  color: #04161c;
  box-shadow: 0 0 28px -6px rgba(53, 200, 240, 0.5);
}

.btn-outline-light {
  border-color: var(--ix-line);
  color: var(--ix-paper);
  background: transparent;
}

.btn-outline-light:hover {
  background-color: transparent;
  border-color: var(--ix-safelight);
  color: var(--ix-safelight);
}

.magic_black, .card, .login, .upload_form, .card-stats {
  background-color: var(--ix-surface);
  border: 1px solid var(--ix-line-soft);
  border-radius: var(--ix-radius);
  box-shadow: none;
}

.upload_form {
  position: relative;
  background-color: var(--ix-raised);
  border-color: var(--ix-line);
  box-shadow: 0 30px 80px -40px rgba(53, 200, 240, 0.4), 0 0 0 1px rgba(53, 200, 240, 0.07);
}

.upload_form::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 2px;
  background: var(--ix-prism);
}

.upload_form .card-header {
  background-color: transparent;
  border-bottom: 1px solid var(--ix-line-soft);
  font-family: Chivo, sans-serif;
  font-size: 0.82rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ix-muted);
}

.upload-area-inner {
  background-color: rgba(0, 0, 0, 0.35);
  border: 1px dashed var(--ix-line) !important;
  border-radius: var(--ix-radius);
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.upload-area-inner:hover, .upload-area-inner.border-primary {
  border-color: var(--ix-safelight) !important;
  background-color: var(--ix-safelight-soft);
}

.upload-icon i { color: var(--ix-safelight) !important; }

.retention-settings {
  background-color: rgba(0, 0, 0, 0.3) !important;
  border: 1px solid var(--ix-line-soft);
  border-radius: var(--ix-radius);
  color: var(--ix-paper);
}

.form-control, .form-select, .input-group-text {
  background-color: rgba(0, 0, 0, 0.35);
  border-color: var(--ix-line);
  color: var(--ix-paper);
  border-radius: var(--ix-radius);
}

.form-control:focus, .form-select:focus {
  background-color: rgba(0, 0, 0, 0.45);
  border-color: var(--ix-safelight);
  box-shadow: 0 0 0 3px var(--ix-safelight-soft);
  color: var(--ix-paper);
}

.form-control::placeholder { color: #6d7f8a; }
.input-group-text.bg-primary { background-color: var(--ix-raised) !important; color: var(--ix-muted); }
input[type="checkbox"], input[type="radio"] { accent-color: var(--ix-safelight); }
.login h3.text-primary, .login h5.text-primary { color: var(--ix-paper) !important; }

.feature.bg-primary {
  background-color: transparent !important;
  background-image: none !important;
  border: 1px solid var(--ix-line);
  color: var(--ix-safelight) !important;
  border-radius: var(--ix-radius);
}

.feature.bg-primary i { color: var(--ix-safelight) !important; }

section.py-5:not(:first-of-type) { border-top: 1px solid var(--ix-line-soft); }

footer, .footer { background-color: transparent; border-top: 1px solid var(--ix-line-soft); }
.footer-list { list-style: none; padding-left: 0; }
.footer-list li { margin-bottom: 0.35rem; }
.footer-list a { color: var(--ix-muted); text-decoration: none; font-size: 0.95rem; }
.footer-list a:hover { color: var(--ix-safelight); }
.footer-title { font-size: 0.82rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ix-muted); margin-bottom: 1rem; }

.alert { border-radius: var(--ix-radius); border: 1px solid var(--ix-line); }
.badge { font-weight: 600; border-radius: 2px; letter-spacing: 0.05em; }
.table { --bs-table-bg: transparent; color: var(--ix-paper); }
.table > :not(caption) > * > * { border-bottom-color: var(--ix-line-soft); }

@keyframes ix-rise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: none; }
}

header .col-lg-8 > div > *, header .upload_form {
  animation: ix-rise 0.7s cubic-bezier(0.2, 0.7, 0.2, 1) backwards;
}

header .col-lg-8 > div > h1 { animation-delay: 0.05s; }
header .col-lg-8 > div > p { animation-delay: 0.16s; }
header .col-lg-8 > div > div { animation-delay: 0.27s; }
header .upload_form { animation-delay: 0.38s; }

@media (prefers-reduced-motion: reduce) {
  *, body::after { transition: none !important; animation: none !important; }
}

header.bg-dark.py-5 { padding-top: 3.5rem !important; padding-bottom: 0 !important; }
header .my-5 { margin-top: 1rem !important; margin-bottom: 2rem !important; }
header .row.align-items-center { align-items: start !important; }

main > section.py-5 { padding-top: 0 !important; padding-bottom: 4rem !important; }
main > section.py-5 > .container.my-5 { margin-top: 0 !important; margin-bottom: 0 !important; padding-top: 5.5rem; }

.upload_form {
  margin-bottom: -3.5rem;
  z-index: 2;
}

h1, .display-5 {
  font-size: clamp(3.2rem, 7vw, 5.6rem);
  letter-spacing: -0.03em;
}

header .lead { margin-top: 1.1rem; font-size: 1.15rem; }
header .d-grid { margin-top: 2rem; }

main .row.gx-5 > [class*="col-lg-4"] { position: relative; }

@media (min-width: 992px) {
  main .row.gx-5 > [class*="col-lg-4"] + [class*="col-lg-4"]::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.35rem;
    bottom: 0.35rem;
    width: 1px;
    background: var(--ix-line-soft);
  }
  main .row.gx-5 > [class*="col-lg-4"] + [class*="col-lg-4"] { padding-left: 2.75rem; }
}

main .feature.bg-primary {
  width: 2.6rem;
  height: 2.6rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: transparent !important;
  font-size: 1.35rem;
  margin-bottom: 0.9rem !important;
}

main h2.h4 {
  font-family: "Instrument Serif", Georgia, serif;
  font-weight: 400;
  font-size: 1.6rem;
  margin-bottom: 0.5rem;
}

main section p.text-white { color: var(--ix-muted) !important; font-size: 0.99rem; }

.upload_form::before { transition: opacity 0.3s ease, filter 0.3s ease; opacity: 0.75; }
.upload_form:hover::before, .upload_form:focus-within::before { opacity: 1; filter: saturate(1.3); }

footer.footer { padding-block: 3.5rem 2rem !important; margin-top: 0 !important; }
footer .footer-logo h2 { margin-bottom: 0.75rem; }
footer .footer-logo h2 p {
  font-family: "Instrument Serif", Georgia, serif;
  font-size: 1.85rem;
  color: var(--ix-paper) !important;
  margin-bottom: 0;
}
footer .footer-logo > p.text-white { color: var(--ix-muted) !important; font-size: 0.97rem; }

.feature {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 3rem;
  width: 3rem;
  font-size: 1.5rem;
}

.nav-pills .nav-link,
.d-flex.flex-column .nav-link {
  color: var(--ix-muted);
  font-family: Chivo, sans-serif;
  font-size: 0.95rem;
  padding: 0.45rem 0.7rem;
  border-radius: var(--ix-radius);
  border-left: 2px solid transparent;
  transition: color 0.15s ease, background-color 0.15s ease, border-color 0.15s ease;
}

.nav-pills .nav-link:hover,
.d-flex.flex-column .nav-link:hover {
  color: var(--ix-paper);
  background-color: rgba(255, 255, 255, 0.04);
  border-left-color: var(--ix-safelight);
}

.nav-pills .nav-link.active,
.nav-pills .show > .nav-link {
  background-color: var(--ix-safelight-soft);
  color: var(--ix-paper);
  border-left-color: var(--ix-safelight);
}

.d-flex.flex-column hr { border-color: var(--ix-line-soft); opacity: 1; }
.d-flex.flex-column .nav-link p { margin-bottom: 0; color: var(--ix-muted); }

.btn-danger {
  background-color: transparent;
  border-color: var(--ix-line);
  color: var(--ix-paper);
}

.btn-danger:hover, .btn-danger:focus-visible {
  background-color: rgba(214, 69, 69, 0.14);
  border-color: #d64545;
  color: #ff8f8f;
}

.card-stats .card-title, .magic_black .card-title {
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ix-muted) !important;
}

.magic_black .card-body h2, .card-stats h2 { color: var(--ix-paper) !important; }

.table-sm td, .table-sm th { color: var(--ix-paper); }
.table-sm td strong { color: var(--ix-paper); }
.magic_black .table { color: var(--ix-muted); }
.magic_black .table strong { color: var(--ix-paper); font-weight: 600; }

.table {
  --bs-table-color: var(--ix-paper);
  --bs-table-bg: transparent;
  --bs-table-border-color: var(--ix-line-soft);
  --bs-table-striped-color: var(--ix-paper);
  --bs-table-striped-bg: rgba(255, 255, 255, 0.025);
  --bs-table-hover-color: var(--ix-paper);
  --bs-table-hover-bg: rgba(53, 200, 240, 0.07);
  --bs-table-active-color: var(--ix-paper);
  --bs-table-active-bg: rgba(53, 200, 240, 0.1);
  color: var(--ix-paper);
}

.table > thead th {
  color: var(--ix-muted);
  font-family: Chivo, sans-serif;
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 600;
  border-bottom-color: var(--ix-line);
}

.table > tbody td { color: var(--ix-paper); border-color: var(--ix-line-soft); }

.dataTables_wrapper { color: var(--ix-muted); }
.dataTables_wrapper .dataTables_length,
.dataTables_wrapper .dataTables_filter,
.dataTables_wrapper .dataTables_info,
.dataTables_wrapper .dataTables_processing { color: var(--ix-muted); }

.dataTables_wrapper .dataTables_length select,
.dataTables_wrapper .dataTables_filter input {
  background-color: rgba(0, 0, 0, 0.35);
  border: 1px solid var(--ix-line);
  color: var(--ix-paper);
  border-radius: var(--ix-radius);
  padding: 0.3rem 0.55rem;
}

.dataTables_wrapper .dataTables_filter input:focus,
.dataTables_wrapper .dataTables_length select:focus {
  border-color: var(--ix-safelight);
  box-shadow: 0 0 0 3px var(--ix-safelight-soft);
  outline: none;
}

.page-link {
  background-color: transparent;
  border-color: var(--ix-line-soft);
  color: var(--ix-muted);
  border-radius: var(--ix-radius) !important;
  margin-inline: 1px;
}

.page-link:hover { background-color: rgba(255, 255, 255, 0.05); border-color: var(--ix-line); color: var(--ix-paper); }
.page-link:focus { box-shadow: 0 0 0 3px var(--ix-safelight-soft); background-color: transparent; color: var(--ix-paper); }

.page-item.active .page-link {
  background-color: var(--ix-safelight);
  border-color: var(--ix-safelight);
  color: #04161c;
  font-weight: 600;
}

.page-item.disabled .page-link { background-color: transparent; border-color: var(--ix-line-soft); color: #4d5c64; }

table.dataTable > thead .sorting:before, table.dataTable > thead .sorting:after,
table.dataTable > thead .sorting_asc:before, table.dataTable > thead .sorting_asc:after,
table.dataTable > thead .sorting_desc:before, table.dataTable > thead .sorting_desc:after { color: var(--ix-muted); opacity: 0.5; }

.btn-link {
  color: var(--ix-muted);
  text-decoration: none;
  font-weight: 500;
}

.btn-link:hover, .btn-link:focus-visible { color: var(--ix-safelight); text-decoration: underline; }

/* ==========================================================================
   User Area & Dashboard & Profile Design Enhancements
   ========================================================================== */

/* User App Layout */
.user-area-wrapper {
  min-height: calc(100vh - 72px);
}

.user-sidebar {
  width: 280px;
  background-color: rgba(17, 22, 25, 0.75);
  backdrop-filter: blur(12px);
  border-right: 1px solid var(--ix-line-soft);
  padding: 1.5rem 1rem;
  transition: all 0.3s ease;
}

@media (max-width: 991.98px) {
  .user-sidebar {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid var(--ix-line-soft);
    padding: 1rem;
  }
}

.sidebar-user-card {
  padding: 0.9rem 1rem;
  background: var(--ix-raised);
  border: 1px solid var(--ix-line-soft);
  border-radius: var(--ix-radius);
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.sidebar-user-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 2px solid var(--ix-safelight);
  object-fit: cover;
  flex-shrink: 0;
}

.sidebar-user-info {
  min-width: 0;
  flex-grow: 1;
}

.sidebar-user-name {
  font-family: Chivo, sans-serif;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--ix-paper);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 0.15rem;
}

.sidebar-user-meta {
  font-size: 0.75rem;
  color: var(--ix-muted);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.status-indicator-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: #22c55e;
  box-shadow: 0 0 8px #22c55e;
  display: inline-block;
}

.sidebar-section-title {
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ix-muted);
  padding: 0.5rem 0.75rem 0.25rem;
  margin-top: 0.75rem;
  font-weight: 600;
}

.sidebar-nav {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.sidebar-nav .nav-link {
  display: flex;
  align-items: center;
  padding: 0.65rem 0.9rem;
  color: var(--ix-muted);
  font-family: Chivo, sans-serif;
  font-size: 0.92rem;
  font-weight: 500;
  border-radius: var(--ix-radius);
  border-left: 3px solid transparent;
  transition: all 0.2s ease;
  text-decoration: none;
}

.sidebar-nav .nav-link i {
  width: 20px;
  font-size: 1.05rem;
  margin-right: 0.75rem;
  color: var(--ix-muted);
  transition: color 0.2s ease, transform 0.2s ease;
  text-align: center;
}

.sidebar-nav .nav-link:hover {
  color: var(--ix-paper);
  background-color: rgba(255, 255, 255, 0.04);
  border-left-color: rgba(53, 200, 240, 0.5);
}

.sidebar-nav .nav-link:hover i {
  color: var(--ix-safelight);
  transform: translateX(2px);
}

.sidebar-nav .nav-link.active {
  color: #fff;
  background-color: var(--ix-safelight-soft);
  border-left-color: var(--ix-safelight);
  font-weight: 600;
}

.sidebar-nav .nav-link.active i {
  color: var(--ix-safelight);
}

.sidebar-footer {
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid var(--ix-line-soft);
}

/* User Content Area */
.user-main-content {
  flex-grow: 1;
  min-width: 0;
  padding: 2rem 2.5rem;
}

@media (max-width: 768px) {
  .user-main-content {
    padding: 1.25rem 0.75rem;
  }
}

/* User Hero Banner */
.user-hero-card {
  position: relative;
  background: linear-gradient(135deg, rgba(23, 30, 35, 0.9) 0%, rgba(17, 22, 25, 0.95) 100%);
  border: 1px solid var(--ix-line);
  border-radius: var(--ix-radius);
  padding: 2rem;
  margin-bottom: 2rem;
  overflow: hidden;
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
}

.user-hero-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--ix-prism);
}

.user-hero-avatar-wrapper {
  position: relative;
  display: inline-block;
}

.user-hero-avatar {
  width: 86px;
  height: 86px;
  border-radius: 50%;
  border: 3px solid var(--ix-safelight);
  box-shadow: 0 0 25px rgba(53, 200, 240, 0.25);
  object-fit: cover;
}

.user-hero-title {
  font-family: "Instrument Serif", Georgia, serif;
  font-size: 2.2rem;
  line-height: 1.1;
  color: var(--ix-paper);
  margin-bottom: 0.35rem;
}

/* Profile Detail Items */
.profile-detail-card {
  background-color: var(--ix-surface);
  border: 1px solid var(--ix-line-soft);
  border-radius: var(--ix-radius);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.profile-detail-card:hover {
  border-color: var(--ix-line);
}

.detail-item-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 0;
  border-bottom: 1px solid var(--ix-line-soft);
}

.detail-item-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.detail-item-row:first-child {
  padding-top: 0;
}

.detail-item-label {
  color: var(--ix-muted);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
}

.detail-item-value {
  color: var(--ix-paper);
  font-size: 0.98rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-detail-action {
  width: 32px;
  height: 32px;
  border-radius: var(--ix-radius);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--ix-line);
  color: var(--ix-paper);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  font-size: 0.82rem;
  transition: all 0.2s ease;
}

.btn-detail-action:hover {
  background: var(--ix-safelight-soft);
  border-color: var(--ix-safelight);
  color: var(--ix-safelight);
}

/* Metric / Stat Cards */
.ix-stat-card {
  background-color: var(--ix-surface);
  border: 1px solid var(--ix-line-soft);
  border-radius: var(--ix-radius);
  padding: 1.35rem 1.25rem;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  position: relative;
  overflow: hidden;
  height: 100%;
}

.ix-stat-card:hover {
  transform: translateY(-2px);
  border-color: var(--ix-line);
  box-shadow: 0 8px 25px -8px rgba(0, 0, 0, 0.5);
}

.ix-stat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.85rem;
}

.ix-stat-label {
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ix-muted);
  font-weight: 600;
}

.ix-stat-icon {
  width: 38px;
  height: 38px;
  border-radius: var(--ix-radius);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--ix-line-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  color: var(--ix-safelight);
}

.ix-stat-value {
  font-family: Chivo, sans-serif;
  font-size: 1.9rem;
  font-weight: 700;
  color: var(--ix-paper);
  line-height: 1.1;
  margin-bottom: 0.35rem;
}

.ix-stat-subtext {
  font-size: 0.8rem;
  color: var(--ix-muted);
}

/* Quick Action Tiles */
.quick-action-card {
  background: var(--ix-surface);
  border: 1px solid var(--ix-line-soft);
  border-radius: var(--ix-radius);
  padding: 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  text-decoration: none;
  color: var(--ix-paper);
  transition: all 0.2s ease;
}

.quick-action-card:hover {
  background: var(--ix-raised);
  border-color: var(--ix-safelight);
  color: var(--ix-paper);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px -6px rgba(53, 200, 240, 0.2);
}

.quick-action-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--ix-radius);
  background: var(--ix-safelight-soft);
  border: 1px solid rgba(53, 200, 240, 0.25);
  color: var(--ix-safelight);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  flex-shrink: 0;
}

.quick-action-content h6 {
  margin-bottom: 0.2rem;
  font-size: 0.95rem;
  font-weight: 600;
}

.quick-action-content p {
  margin-bottom: 0;
  font-size: 0.8rem;
  color: var(--ix-muted);
}

/* Danger Zone Card */
.danger-zone-card {
  background: rgba(214, 69, 69, 0.04);
  border: 1px solid rgba(214, 69, 69, 0.25);
  border-radius: var(--ix-radius);
  padding: 1.5rem;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.danger-zone-card:hover {
  background: rgba(214, 69, 69, 0.07);
  border-color: rgba(214, 69, 69, 0.45);
}

/* Modal Theming */
.modal-content {
  background-color: var(--ix-raised);
  border: 1px solid var(--ix-line);
  border-radius: var(--ix-radius);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7);
  color: var(--ix-paper);
}

.modal-header {
  border-bottom: 1px solid var(--ix-line-soft);
  padding: 1.25rem 1.5rem;
}

.modal-header .modal-title {
  font-family: Chivo, sans-serif;
  font-weight: 600;
  font-size: 1.15rem;
  color: var(--ix-paper);
}

.modal-footer {
  border-top: 1px solid var(--ix-line-soft);
  padding: 1rem 1.5rem;
}

.modal-body {
  padding: 1.5rem;
}

.btn-close {
  filter: invert(1) grayscale(100%) brightness(200%);
}

/* Profile Tabs & Pills */
.profile-tabs-card {
  position: relative;
  background: linear-gradient(135deg, rgba(23, 30, 35, 0.95) 0%, rgba(17, 22, 25, 0.98) 100%);
  border: 1px solid var(--ix-line);
  border-radius: var(--ix-radius);
  padding: 0.65rem 0.85rem;
  margin-bottom: 2rem;
  overflow: hidden;
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
}

.profile-tabs-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--ix-prism);
}

.profile-tabs-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  padding: 0;
  background: transparent;
  border: none;
  margin-bottom: 0;
}

.profile-tabs-nav .nav-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem 1.15rem;
  border-radius: var(--ix-radius);
  color: var(--ix-muted);
  font-weight: 500;
  font-size: 0.88rem;
  border: 1px solid transparent;
  transition: all 0.2s ease;
  background: rgba(255, 255, 255, 0.03);
  text-decoration: none;
  cursor: pointer;
}

.profile-tabs-nav .nav-link:hover {
  color: var(--ix-paper);
  background: rgba(255, 255, 255, 0.07);
  border-color: var(--ix-line-soft);
}

.profile-tabs-nav .nav-link.active {
  color: #fff;
  background: var(--ix-raised);
  border-color: var(--ix-safelight);
  box-shadow: 0 4px 16px -4px rgba(53, 200, 240, 0.35);
}

.profile-tabs-nav .nav-link.active i {
  color: var(--ix-safelight);
}

/* Copy box container */
.ix-copy-box {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--ix-line-soft);
  border-radius: var(--ix-radius);
  padding: 0.75rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.ix-copy-box code {
  color: var(--ix-safelight);
  font-size: 0.88rem;
  word-break: break-all;
}

/* Step badges for 2FA and setup guides */
.ix-step-pill {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--ix-safelight-soft);
  color: var(--ix-safelight);
  border: 1px solid rgba(53, 200, 240, 0.3);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 0.82rem;
  flex-shrink: 0;
}

/* ========================================================================= */
/* GALLERY COMPONENT STYLES                                                  */
/* ========================================================================= */

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.25rem;
}

.gallery-card {
  background: var(--ix-surface);
  border: 1px solid var(--ix-line-soft);
  border-radius: var(--ix-radius);
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.gallery-card:hover {
  transform: translateY(-3px);
  border-color: var(--ix-safelight);
  box-shadow: 0 10px 25px -8px rgba(0, 0, 0, 0.6);
}

.gallery-card.is-selected {
  border-color: var(--ix-safelight);
  box-shadow: 0 0 0 2px var(--ix-safelight-soft), 0 8px 20px rgba(53, 200, 240, 0.2);
}

.gallery-card-thumb {
  position: relative;
  aspect-ratio: 16 / 10;
  background: #06080a;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gallery-card-thumb canvas,
.gallery-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.gallery-card-checkbox {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 15;
  background: rgba(8, 10, 12, 0.75);
  backdrop-filter: blur(4px);
  border: 1px solid var(--ix-line-soft);
  border-radius: 6px;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.gallery-card-checkbox:hover {
  border-color: var(--ix-safelight);
}

.gallery-card-checkbox input {
  width: 18px;
  height: 18px;
  cursor: pointer;
  accent-color: var(--ix-safelight);
}

.gallery-card-ext {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 15;
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  font-weight: 700;
  text-transform: uppercase;
  background: rgba(8, 10, 12, 0.75);
  backdrop-filter: blur(4px);
  border: 1px solid var(--ix-line-soft);
  color: var(--ix-safelight);
  padding: 2px 7px;
  border-radius: 4px;
}

.gallery-card-hover {
  position: absolute;
  inset: 0;
  background: rgba(8, 10, 12, 0.75);
  backdrop-filter: blur(2px);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  opacity: 0;
  transition: opacity 0.2s ease;
  z-index: 10;
}

.gallery-card:hover .gallery-card-hover {
  opacity: 1;
}

.gallery-card-hover .btn-action {
  width: 36px;
  height: 36px;
  border-radius: var(--ix-radius);
  background: var(--ix-raised);
  border: 1px solid var(--ix-line);
  color: var(--ix-paper);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  transition: all 0.2s ease;
  text-decoration: none;
}

.gallery-card-hover .btn-action:hover {
  background: var(--ix-safelight-soft);
  border-color: var(--ix-safelight);
  color: var(--ix-safelight);
  transform: scale(1.08);
}

.gallery-card-hover .btn-action.btn-action-danger:hover {
  background: rgba(239, 68, 68, 0.15);
  border-color: #ef4444;
  color: #f87171;
}

.gallery-card-body {
  padding: 0.85rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  background: var(--ix-surface);
  border-top: 1px solid var(--ix-line-soft);
}

.gallery-card-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.gallery-card-title code {
  color: var(--ix-paper);
  font-size: 0.85rem;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.gallery-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.75rem;
  color: var(--ix-muted);
}

/* Floating Batch Action Toolbar */
.floating-batch-bar {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  z-index: 1050;
  background: rgba(17, 22, 25, 0.95);
  backdrop-filter: blur(12px);
  border: 1px solid var(--ix-safelight);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.6), 0 0 20px -5px rgba(53, 200, 240, 0.3);
  border-radius: 50px;
  padding: 0.5rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
  opacity: 0;
  pointer-events: none;
}

.floating-batch-bar.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
  pointer-events: auto;
}

/* Gallery Controls Toolbar */
.gallery-toolbar {
  background: var(--ix-surface);
  border: 1px solid var(--ix-line-soft);
  border-radius: var(--ix-radius);
  padding: 0.75rem 1rem;
  margin-bottom: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

/* Pagination styles */
.ix-pagination .page-link {
  background-color: var(--ix-surface);
  border-color: var(--ix-line-soft);
  color: var(--ix-paper);
  padding: 0.45rem 0.85rem;
  font-size: 0.85rem;
  transition: all 0.2s ease;
}

.ix-pagination .page-link:hover {
  background-color: var(--ix-raised);
  border-color: var(--ix-safelight);
  color: var(--ix-safelight);
}

.ix-pagination .page-item.active .page-link {
  background-color: var(--ix-safelight);
  border-color: var(--ix-safelight);
  color: #080a0c;
  font-weight: 600;
}

.ix-pagination .page-item.disabled .page-link {
  background-color: var(--ix-surface);
  border-color: var(--ix-line-soft);
  color: var(--ix-muted);
  opacity: 0.5;
}

/* User Badges & Ranks System */
.pn-badge,
.pn_badge {
  display: inline-flex !important;
  align-items: center;
  gap: 0.35rem;
  padding: 0.24rem 0.65rem !important;
  font-size: 0.72rem !important;
  font-weight: 600 !important;
  border-radius: 9999px !important;
  line-height: 1.25 !important;
  white-space: nowrap !important;
  margin: 0 !important;
  text-decoration: none;
  transition: all 0.2s ease;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
  letter-spacing: 0.02em;
}

.pn-badge:hover,
.pn_badge:hover {
  transform: translateY(-1px);
  filter: brightness(1.2);
}

.pn-badge i,
.pn_badge i {
  font-size: 0.72rem;
}

/* Badge Color Themes matching ImagicX Design System */
.pn-badge-primary,
.pn_badge.bg-primary {
  background: rgba(53, 200, 240, 0.15) !important;
  color: #35c8f0 !important;
  border: 1px solid rgba(53, 200, 240, 0.4) !important;
}

.pn-badge-success,
.pn_badge.bg-success {
  background: rgba(34, 197, 94, 0.15) !important;
  color: #4ade80 !important;
  border: 1px solid rgba(34, 197, 94, 0.4) !important;
}

.pn-badge-info,
.pn_badge.bg-info {
  background: rgba(56, 189, 248, 0.15) !important;
  color: #38bdf8 !important;
  border: 1px solid rgba(56, 189, 248, 0.4) !important;
}

.pn-badge-warning,
.pn_badge.bg-warning {
  background: rgba(234, 179, 8, 0.15) !important;
  color: #facc15 !important;
  border: 1px solid rgba(234, 179, 8, 0.4) !important;
}

.pn-badge-danger,
.pn_badge.bg-danger {
  background: rgba(239, 68, 68, 0.15) !important;
  color: #f87171 !important;
  border: 1px solid rgba(239, 68, 68, 0.4) !important;
}

.pn-badge-secondary,
.pn-badge-dark,
.pn_badge.bg-secondary,
.pn_badge.bg-dark {
  background: rgba(255, 255, 255, 0.08) !important;
  color: #cbd5e1 !important;
  border: 1px solid rgba(255, 255, 255, 0.15) !important;
}
