ul.rating-field li { list-style-type: none; display: inline; margin-right: 1em; }
ul.rating-field label { display: inline; }

.upload_result_thumb {
  height: 46px; margin: auto; display: block;
  transition: transform .2s;
  transform-origin: bottom right;
}

.upload_result_thumb:hover {
  position: relative;
  transform: scale(6, 6);
}

.publicize-thumb {
  margin: auto; display: block;
  transition: transform .2s;
  transform-origin: top center;
  z-index: 100;
}

.publicize-thumb:hover {
  position: relative;
  transform: scale(6, 6);
}

.btn.htmx-request {
    background: linear-gradient(225deg, #00abab, #00daab, #dd00ab, #abe400, #d9ab00);
    background-size: 300% 300%;
    animation: cycle 1s ease infinite;
}

.btn {
    border: 1px solid var(--color-secondary);
    background: transparent;
    color: var(--color-text);
    text-shadow: none;
}

.btn:hover, .btn:focus, .btn:active {
    background: var(--color-secondary);
    color: white;
}


.btn-primary {
    border: 1px solid var(--color-primary);
    background: transparent;
    color: var(--color-primary);
    text-shadow: none;
}

.btn-primary:hover, .btn-primary:focus, .btn-primary:active {
    background: var(--color-primary);
    color: white;
}



.btn-danger {
  border: 1px solid var(--color-primary);
  background: var(--color-primary);
  color: white;
  text-shadow: none;
}

.btn-danger:hover, .btn-danger:focus, .btn-danger:active {
  background: var(--color-bg);
  color: var(--color-text);
}

button.unstyled {
    border: none;
    background: none;
}
button.unstyled:hover {
  color: var(--color-primary)
}

@keyframes cycle {
    0% {
      background-position: 94% 0%; }
    50% {
      background-position: 7% 100%; }
    100% {
      background-position: 94% 0%; } }

/* HA STYLES */

:root {
  --color-bg: #f3f2e7;
  --color-text: #000;
  --color-primary: #ef4d37;
  --color-secondary: #b5a26d;
  --max-width: 1400px
}

body {
  background-color: var(--color-bg);
  font-family: Barlow, sans-serif;
}

a {
  color: var(--color-primary);
}

a:hover {
  color: var(--color-primary);
  text-decoration: underline;
}

a.text-link {
  color: var(--color-text);
}
a.text-link:hover {
  color: var(--color-primary);
  text-decoration: none;
}

/* START HA HEADER */

header.ha-header {
  /* max-width: var(--max-width); */
  max-width: 1200px;
  display: flex;
  margin: 24px auto 24px auto;
  padding: 0 12px;
}

header.ha-header .halinks {
  margin: auto 0 auto auto;
  list-style: none;
  display: flex;
  justify-content: end;
  flex-wrap: wrap;
}

header.ha-header .halinks li {
  padding: 0 24px;
  border-right: 1px solid var(--color-secondary);
}

header.ha-header .halinks li:last-child {
  border-right: none;
}

header.ha-header .halinks a {
  color: inherit;
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
}

header.ha-header .halinks a.active {
  font-weight: bold;
}

header.ha-header .halinks a:hover {
  text-decoration: underline;
}

header.ha-header .logo {
  display: block;
  width: 128px;
  margin-right: 12px;
  flex-shrink: 0;
}

/* END HA HEADER */

.navbar .navbar-inner {
  background: inherit;
  border: 2px solid var(--color-secondary);
  border-width: 0 0 2px 0;
  border-radius: 0;
  box-shadow: none;
}

.navbar .nav > li > a, .navbar .nav > .active > a {
  color: var(--color-text);
}

.navbar .nav > li > a:hover, .navbar .nav > .active > a:hover {
  color: var(--color-primary);
  background-color: inherit;
  box-shadow: inherit;
}

.navbar .nav > .active > a {
  background: inherit;
  /*border: 2px solid var(--color-primary);
  border-width: 2px 2px 2px 2px;*/
  font-weight: bold;
  box-shadow: none;
}

.nav-tabs a {
  color: var(--color-text);
}
.nav .dropdown-toggle .caret {
    border-top-color: var(--color-text); border-bottom-color: var(--color-text);
}

.nav-tabs {
  border-bottom: 1px solid var(--color-secondary);
}

.nav-tabs > .active > a {
  font-weight: bold;
  /* border: 2px solid var(--color-primary); */
  border: 1px solid transparent;
  background: inherit;
  color: var(--color-text);
}

.nav-tabs > li > a:hover {
  color: var(--color-primary);
  background: inherit;
  border: 1px solid transparent;
}

.nav-tabs > .active > a:hover {
  /* border: 2px solid var(--color-primary); */
  border: 1px solid transparent;
  background: inherit;
  color: var(--color-text);
  cursor: pointer;
}

.table {
  border: 0;
}

.table tr td, .table tr th {
  border: 0;
  border-bottom: 1px solid var(--color-secondary);
}

.table-striped tbody > tr:nth-child(2n+1) > td, .table-striped tbody > tr:nth-child(2n+1) > th {
  background-color: inherit;
}

.table-hover tbody tr:hover > td, .table-hover tbody tr:hover > th {
  background-color: rgba(0, 0, 0, 0.05);
}

p {
  font-size: 1.2em;
  line-height: 1.5em;
}

.missing-asset-icon {
  font-size: 128px;
  text-align: center;
  color: var(--color-secondary);
  min-height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none !important;
}

.organization-icon {
  width: 16px;
  height: 16px;
  vertical-align: text-top;
}

h2 small .organization-icon {
  width: 24px;
  height: 24px;
  vertical-align: text-bottom;
}

hr {
  border-color: var(--color-secondary);
  border-style: solid;
}

.infobox {
  border: 2px solid var(--color-secondary);
  margin: 8px;
  padding: 8px;
  font-size: 16px;
  text-align: center;
}

.inline-form input {
  margin-bottom: 0;
}


.selected {
  position: fixed;
  bottom: 0;
  right: 0;
  margin: 4px;
  padding: 4px;
  border: 1px solid #ccc;
  background: white;
  border-radius: 3px;
  max-width: 60%;
}

.selected-buttons {
  /* text-align: right; */
}
.selected-buttons input[type=text] {
  margin: 0; padding: 2px; width: 100px;
}

.selected form {
  /*
  display: inline-block; border: 1px solid #bbb; padding: 2px; border-radius: 4px; margin: 0;
  */    
}
.selected .btn {
  font-size: 12px;
}
.selected .btn:not(a) {
  height: 25px;
}
.selected a.btn {
  height: 16px;
}
.selected input {
  height: 19.5px;
}
.selected .input-append {
  margin: 0;
}
.col-id {width: 42px;}
.col-code {width: 72px;}
.col-flags {width: 82px;}
.flags {display: flex; gap: 4px; width: 100%;}
.asset-category {font-size: 12px; min-width: 90px; display: inline-block;}

.selected .nav {
  margin-bottom: 2px;
}

/* Inline Create (companies/party/etc.) */
.inline-create-btn { margin-left: 6px; }

.inline-create-popup {
  position: absolute;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 4px;
  padding: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  z-index: 10000;
}

.inline-create-popup.is-error {
  border-color: #dc3545;
}

.inline-create-label { display: block; margin-bottom: 4px; }
.inline-create-input { min-width: 260px; margin-right: 6px; }
.inline-create-controls { margin-top: 6px; }
.inline-create-cancel { margin-left: 6px; }

.event-timeline {
  display: flex;
  border-top: 1px solid var(--color-secondary);
  border-bottom: 1px solid var(--color-secondary);
}

.event-timeline li {
  margin-right: 12px;
  list-style: none;
}

.event-timeline li a {
  color: var(--color-secondary);
  padding: 4px;
}

.event-timeline li.event-displayed a {
  color: var(--color-primary);
  padding: 4px;
}

.event-table {
    border-collapse: collapse;
    margin: 8px 0;
    font-size: 14px;
    width: 100%;
    /* max-width: 800px; */
    background: white;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.event-table-nested {
    margin: 4px 0;
    box-shadow: none;
    border: 1px solid #ddd;
}

.event-table thead th {
    background: #f5f5f5;
    padding: 2px 12px;
    text-align: left;
    font-weight: 600;
    border-bottom: 2px solid #ddd;
}

.event-type-header {
    background: #4a90d9 !important;
    color: white;
    font-family: monospace;
}

.event-table-nested .event-type-header {
    background: #6ba3e0 !important;
}

.event-table tbody tr:nth-child(even) {
    background: #fafafa;
}

.event-table tbody tr:hover {
    background: #f0f7ff;
}

.event-table td {
    padding: 2px 12px;
    border-bottom: 1px solid #eee;
    vertical-align: top;
}

.event-key {
    font-weight: 500;
    color: #333;
    font-family: monospace;
    white-space: nowrap;
    width: 1%;
    background: #f9f9f9;
}

.event-value-cell {
    word-break: break-word;
}

.event-value {
    font-family: monospace;
    color: #444;
}

.event-value-string {
    color: #2e7d32;
}

.event-value-number {
    color: #e64949;
}

.event-null {
    color: #999;
    font-style: italic;
}

.event-empty-list {
    color: #999;
    font-family: monospace;
}

.event-simple-list {
    font-family: monospace;
    color: #444;
}

.event-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.event-list-item {
    display: flex;
    flex-direction: column;
}

.event-list-index {
    font-family: monospace;
    color: #888;
    font-size: 12px;
    margin-bottom: 2px;
}

.has-tooltip {
    cursor: help;
    font-size: 12px;
    margin-left: 4px;
}

.event-details-header {
    font-size: 20px;
    margin: 20px;
}

.event-details-header h2 {
    margin-bottom: 10px;
}

.event-object-container {
    margin: 20px;
}