/* Excel Nails CRM — theme on top of Tabler. v=7
   Layout pattern follows popular CRMs (HubSpot / Salesforce style):
   dark left sidebar, slim top bar, soft background, white cards.
   Palette: deep plum sidebar + rose "polish" accent. Employees can
   request different colors/branding in the Look & feel section;
   a re-theme is then just a revision to this file + the logo mark. */

:root {
  --xl-accent: #d9436f;
  --xl-accent-dark: #b92f59;
  --xl-accent-soft: #fbe9ef;
  --xl-ink: #262038;
  --xl-bg: #f6f5f9;
  --xl-border: #e8e4f0;
}

body { background: var(--xl-bg); color: #322d47; }
a { color: var(--xl-accent-dark); }
a:hover { color: var(--xl-accent); }

/* --- Buttons ------------------------------------------------------------ */
.btn-primary {
  --tblr-btn-bg: var(--xl-accent);
  --tblr-btn-border-color: var(--xl-accent);
  --tblr-btn-hover-bg: var(--xl-accent-dark);
  --tblr-btn-hover-border-color: var(--xl-accent-dark);
  --tblr-btn-active-bg: var(--xl-accent-dark);
  background-color: var(--xl-accent);
  border-color: var(--xl-accent);
}
.btn-primary:hover, .btn-primary:active { background-color: var(--xl-accent-dark); border-color: var(--xl-accent-dark); }
.btn-outline-primary { color: var(--xl-accent-dark); border-color: var(--xl-accent); }
.btn-outline-primary:hover { background-color: var(--xl-accent); border-color: var(--xl-accent); }

/* --- Sidebar -------------------------------------------------------------- */
.xl-sidebar {
  background: linear-gradient(180deg, #2d2142 0%, #211930 100%) !important;
  border-right: none;
}
.xl-brand { display: flex; align-items: center; gap: .6rem; padding-top: .9rem; }
.xl-logo {
  display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: 10px; flex: none;
  background: linear-gradient(135deg, var(--xl-accent) 0%, #f0764f 100%);
  color: #fff; font-weight: 800; font-size: 1.05rem;
  box-shadow: 0 4px 10px rgba(217, 67, 111, .4);
}
.xl-brand-text { display: flex; flex-direction: column; line-height: 1.05; color: #fff; font-weight: 700; }
.xl-brand-text small { color: rgba(255,255,255,.55); font-weight: 600; letter-spacing: .14em; font-size: .62rem; }
.xl-sidebar .nav-link { border-radius: 8px; margin: 1px 8px; color: rgba(255,255,255,.78); }
.xl-sidebar .nav-link:hover { background: rgba(255,255,255,.07); color: #fff; }
.xl-sidebar .nav-link.active { background: rgba(217,67,111,.22); color: #fff; box-shadow: inset 3px 0 0 var(--xl-accent); }
.xl-icon { width: 20px; height: 20px; }
.xl-navlabel {
  padding: .9rem 1rem .3rem; font-size: .64rem; font-weight: 700;
  letter-spacing: .14em; color: rgba(255,255,255,.38);
}
.xl-logout { background: none; border: 0; width: calc(100% - 16px); text-align: left; }
.xl-sideuser {
  margin: 1rem; padding: .7rem .8rem; border-radius: 10px;
  background: rgba(255,255,255,.06); color: #fff; font-weight: 600; font-size: .85rem;
}
.xl-sideuser small { display: block; color: rgba(255,255,255,.5); font-weight: 500; text-transform: capitalize; }

/* --- Top bar, cards, headings ---------------------------------------------- */
.xl-topbar { background: #fff; border-bottom: 1px solid var(--xl-border); padding: .55rem 0; }
.xl-topbar-title { font-weight: 700; color: var(--xl-ink); }

/* Page headers: Tabler's own .page-header is flex-direction:column
   (it is designed to wrap an inner .row), so used bare it stacks the
   title above the right-side buttons, hard against the first card.
   Force the demo layout: one row, title left, buttons right, clear
   air below. The margin needs !important — measured in a headless
   replica (3 Nov 2026): without it Tabler's margin shorthand wins
   the cascade and the gap collapses to ~0px; with it, 25px. */
.page-header {
  flex-direction: row; align-items: center; flex-wrap: wrap;
  gap: .5rem 1rem; margin-bottom: 1.5rem !important;
}
.page-title { color: var(--xl-ink); font-weight: 750; letter-spacing: -.01em; }
.card {
  border: 1px solid var(--xl-border); border-radius: 14px;
  box-shadow: 0 1px 3px rgba(38, 32, 56, .05);
}
.card-header { border-bottom: 1px solid var(--xl-border); background: #fff; border-radius: 14px 14px 0 0 !important; }
.card-title { color: var(--xl-ink); }
.alert { border-radius: 10px; }
.form-control:focus, .form-select:focus { border-color: var(--xl-accent); box-shadow: 0 0 0 .2rem rgba(217,67,111,.15); }
.table thead th { text-transform: uppercase; font-size: .68rem; letter-spacing: .06em; color: #8a84a0; }

/* Badges/pills: soft tints only (Alex: the solid saturated Tabler badges
   were harsh on the eyes). Slightly larger, calmer, sentence-case. */
.badge {
  font-weight: 600; letter-spacing: .01em; text-transform: none;
  padding: .32em .6em; border-radius: 999px; vertical-align: middle;
}

/* --- Auth (login / setup) ----------------------------------------------------- */
.xl-auth-card { overflow: hidden; }
.xl-auth-brand {
  background: linear-gradient(150deg, #2d2142 0%, #4a2445 55%, var(--xl-accent) 130%);
  color: #fff; min-height: 100%;
}
.xl-auth-brand .xl-logo { width: 44px; height: 44px; font-size: 1.3rem; border-radius: 12px; }
.xl-auth-tag { font-size: 1.35rem; font-weight: 750; line-height: 1.25; }
.xl-auth-sub { color: rgba(255,255,255,.72); }

/* --- Requirements editor bits --------------------------------------------------- */
details > summary { list-style: none; cursor: pointer; }
details > summary::-webkit-details-marker { display: none; }
.list-group-item details { min-width: 260px; }
@media (max-width: 640px) {
  .list-group-item details { min-width: 0; width: 100%; }
  .list-group-item .d-flex { flex-wrap: wrap; }
}
