/* ui-tablehover.css
   Unified modern neutral-gray styling:
   - Bootstrap 2 tables (.table): zebra + hover + compact rows
   - Yii CDetailView (table.detail-view): same zebra + hover + compact
   - Right sidebar "Operations" menu: neutral (no blue), zebra + hover + compact
   Notes:
   - Uses HEX colors (not rgba) to avoid blending differences with different parent backgrounds.
*/

/* =========================
   Color tokens (documentation)
   =========================
   zebra odd: #eceef1
   hover:     #e0e3e8
   text:      #111827
   text muted:#374151
   header bd: #d1d5db
*/

/* =========================
   Bootstrap 2 tables (.table)
   ========================= */

.table thead th {
  border-bottom: 1px solid #d1d5db;
  color: #374151;
  font-weight: 600;
}

/* no row separators (keep it airy) */
.table tbody tr td,
.table tbody tr th {
  border-top: 0;
}

/* COMPACT rows */
.table tbody td,
.table tbody th {
  padding: 4px 8px;
  line-height: 1.25;
}

/* inputs/selects inside table (filters / inline) should not inflate height */
.table tbody input,
.table tbody select {
  margin: 0;
  padding: 2px 6px;
  line-height: 1.2;
  height: auto;
}

/* Zebra */
.table tbody tr:nth-child(odd) td,
.table tbody tr:nth-child(odd) th {
  background-color: #eceef1;
}

/* Hover */
.table tbody tr:hover td,
.table tbody tr:hover th {
  background-color: #e0e3e8;
}

/* Bootstrap 2 .table-striped compatibility */
.table.table-striped tbody tr:nth-child(odd) td,
.table.table-striped tbody tr:nth-child(odd) th {
  background-color: #eceef1;
}


/* =========================
   Yii CDetailView (.detail-view)
   ========================= */

table.detail-view {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background-color: #ffffff; /* force stable base */
}

/* cells (compact) */
table.detail-view tr th,
table.detail-view tr td {
  border-top: 0;
  padding: 4px 8px;
  line-height: 1.25;
  vertical-align: top;
  background-color: #ffffff; /* force stable base */
}

/* Zebra (Yii often outputs tr.odd / tr.even) */
table.detail-view tr.odd th,
table.detail-view tr.odd td {
  background-color: #eceef1;
}

/* fallback if odd/even classes are not present */
table.detail-view tr:nth-child(odd) th,
table.detail-view tr:nth-child(odd) td {
  background-color: #eceef1;
}

/* Hover */
table.detail-view tr:hover th,
table.detail-view tr:hover td {
  background-color: #e0e3e8;
}

/* labels */
table.detail-view th {
  color: #374151;
  font-weight: 600;
  white-space: nowrap;
  width: 1%;
  padding-right: 10px;
}

/* values */
table.detail-view td {
  color: #111827;
}


/* =========================
   Right sidebar "Operations" menu
   ========================= */

/* Neutralize Bootstrap 2 blue-ish .well in typical sidebar columns */
.span2 .well,
.span3 .well,
.span4 .well {
  background-color: #ffffff;
  border: 0;
  box-shadow: none;
  padding: 8px; /* compact */
}

/* If there is a header inside the well */
.span2 .well h3,
.span2 .well h4,
.span3 .well h3,
.span3 .well h4,
.span4 .well h3,
.span4 .well h4,
.span2 .well .nav-header,
.span3 .well .nav-header,
.span4 .well .nav-header {
  color: #374151;
  font-weight: 600;
  background: transparent;
  padding: 4px 8px;
  margin: 0 0 4px 0;
}

/* reset lists */
ul.operations,
ul.sidebar,
ul.nav-list,
.well ul,
.well ul.operations {
  margin: 0;
  padding: 0;
  list-style: none;
}

/* items/links (compact) */
ul.operations li a,
ul.sidebar li a,
ul.nav-list li a,
.well ul li a {
  display: block;
  padding: 4px 8px;
  line-height: 1.25;
  color: #374151;         /* neutral gray (not blue) */
  text-decoration: none;
  border-radius: 3px;
}

/* visited should remain neutral (avoid browser default blue/purple) */
ul.operations li a:visited,
ul.sidebar li a:visited,
ul.nav-list li a:visited,
.well ul li a:visited {
  color: #374151;
}

/* Zebra */
ul.operations li:nth-child(odd) a,
ul.sidebar li:nth-child(odd) a,
ul.nav-list li:nth-child(odd) a,
.well ul li:nth-child(odd) > a {
  background-color: #eceef1;
}

/* Hover */
ul.operations li a:hover,
ul.sidebar li a:hover,
ul.nav-list li a:hover,
.well ul li a:hover {
  background-color: #e0e3e8;
  color: #111827;
  text-decoration: none;
}

/* Active (Yii CMenu uses li.active) */
ul.operations li.active > a,
ul.sidebar li.active > a,
ul.nav-list li.active > a,
.well ul li.active > a {
  background-color: #e0e3e8;
  color: #111827;
  font-weight: 600;
}

/* Icons inside menu links */
ul.operations li a i,
ul.sidebar li a i,
ul.nav-list li a i,
.well ul li a i {
  opacity: 0.75;
  margin-right: 4px;
}



/* =========================
   OPERATIONS (Yii CPortlet / CMenu) – neutral gray, no zebra
   ========================= */

/* 1) Портлет контейнер (махаме синьо/бордъри от темата) */
.portlet {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  margin: 0 0 12px 0 !important;
}

/* 2) Заглавката "Operations" (обикновено е .portlet-decoration) */
.portlet .portlet-decoration {
  background: #f3f4f6 !important; /* неутрално сиво */
  color: #374151 !important;
  border: 0 !important;
  border-radius: 4px 4px 0 0 !important;
  padding: 6px 10px !important;
  font-weight: 600 !important;
}

/* Ако заглавката е рендерирана като h3/h4 вътре */
.portlet .portlet-decoration h3,
.portlet .portlet-decoration h4 {
  margin: 0 !important;
  padding: 0 !important;
  font-size: 12px !important;
  line-height: 1.2 !important;
  color: #374151 !important;
}

/* 3) Съдържание на портлета (самия “панел”) */
.portlet .portlet-content {
  background: #f3f4f6 !important;
  border: 0 !important;
  border-radius: 0 0 4px 4px !important;
  padding: 6px !important;
}

/* 4) Самият списък operations */
ul.operations {
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
  background: transparent !important; /* без зебра */
}

/* 5) Линковете – без синьо, без зебра */
ul.operations li a {
  display: block !important;
  padding: 5px 8px !important;   /* compact */
  line-height: 1.25 !important;
  color: #374151 !important;      /* неутрално сиво */
  background: transparent !important;
  text-decoration: none !important;
  border-radius: 3px !important;
}

/* visited да не става синьо/лилаво */
ul.operations li a:visited {
  color: #374151 !important;
}

/* 6) Hover – “пълни” реда */
ul.operations li a:hover {
  background: #e5e7eb !important;
  color: #111827 !important;
}

/* 7) Active (ако има) */
ul.operations li.active > a {
  background: #e5e7eb !important;
  color: #111827 !important;
  font-weight: 600 !important;
}

/* 8) Ако има икони */
ul.operations li a i {
  opacity: 0.75 !important;
  margin-right: 4px !important;
}

