import { css } from '//resources/lit/v3_0/lit.rollup.js';
import { getCss as getCrHiddenStyleLit } from '//resources/cr_elements/cr_hidden_style_lit.css.js';
import { getCss as getCrSharedStyleLit } from '//resources/cr_elements/cr_shared_style_lit.css.js';
import '//resources/cr_elements/cr_shared_vars.css.js';
import { getCss as getMdSelectLit } from '//resources/cr_elements/md_select_lit.css.js';
let instance = null;
export function getCss() {
    return instance || (instance = [...[getCrSharedStyleLit(), getCrHiddenStyleLit(), getMdSelectLit()], css `
:host {
  display: block;
  margin: 0 auto;
  max-width: 800px;
  padding: 32px 24px;
  font-family: inherit;
  color: var(--cr-primary-text-color);
}

h1 {
  margin: 0 0 24px 0;
  padding: 0;
  text-align: center;
  font-size: 24px;
  font-weight: 500;
  color: var(--cr-secondary-text-color);
}

/* Tab Box Overrides */
cr-tab-box {
  --cr-tab-box-tab-selected-color: var(--cr-checked-color);
  --tabs-background-color: transparent;
  --tabs-border-color: var(--cr-separator-color);
  --tabs-hover-text-color: var(--cr-primary-text-color);
  --tabs-unselected-text-color: var(--cr-secondary-text-color);
}

div[slot='panel'] {
  padding-top: 32px;
}

.card {
  background-color: var(--cr-card-background-color);
  border-radius: var(--cr-card-border-radius);
  box-shadow: var(--cr-card-shadow);
  padding: 20px;
  margin-bottom: 24px;
}

.card h2 {
  font-size: 16px;
  font-weight: 500;
  margin-top: 0;
  margin-bottom: 16px;
  color: var(--cr-primary-text-color);
}

#textInput {
  --cr-input-error-display: none;
  width: 100%;
}

cr-textarea {
  width: 100%;
}

cr-slider {
  width: 250px;
  --cr-slider-active-color: var(--cr-checked-color);
  --cr-slider-knob-color: var(--cr-checked-color);
  --cr-slider-container-color: var(--cr-primary-text-color);
  --cr-slider-bar-height: 4px;
  line-height: inherit;
}

.container {
  display: flex;
  align-items: center;
  margin-bottom: 16px;
}

.model-options {
  margin-bottom: 20px;
}

.model-options > .container {
  margin-bottom: 16px;
}

.model-options .mode-label,
.model-options .slider-percentage {
  color: var(--cr-secondary-text-color);
  font-size: 13px;
  width: 160px;
  text-align: left;
  display: inline-block;
  font-weight: 500;
}

ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

li {
  padding: 12px;
  border-bottom: 1px solid var(--cr-separator-color);
  transition: background-color 0.2s;
}

li:last-child {
  border-bottom: none;
}

li:hover {
  background-color: var(--cr-hover-on-prominent-background-color);
}

li a {
  text-decoration: none;
  color: var(--cr-link-color);
  font-weight: 500;
}

li a:hover {
  text-decoration: underline;
}

.action-button {
  margin-top: 16px;
}

/* Logging Table */
table {
  width: 100%;
  border-collapse: collapse;
  font-family: monospace;
  font-size: 12px;
  border: 1px solid var(--cr-separator-color);
  border-radius: 4px;
  overflow: hidden;
}

thead {
  background-color: var(--cr-hover-background-color);
}

th,
td {
  padding: 8px 12px;
  text-align: left;
  border-bottom: 1px solid var(--cr-separator-color);
}

th {
  font-weight: 600;
  color: var(--cr-secondary-text-color);
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: 0.5px;
}

tbody tr:last-child td {
  border-bottom: none;
}

tbody tr:hover {
  background-color: var(--cr-hover-background-color);
}

.time {
  width: 100px;
  color: var(--cr-secondary-text-color);
  white-space: nowrap;
}

.source-location {
  width: 250px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 250px;
}

.source-location a {
  color: var(--cr-link-color);
  text-decoration: none;
}

.source-location a:hover {
  text-decoration: underline;
}

.message {
  color: var(--cr-primary-text-color);
  word-break: break-all;
}

/* Debugging Tab */
.debug-section {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.debug-row {
  display: flex;
  align-items: center;
  gap: 16px;
}

.debug-row > span:first-child {
  width: 200px;
  font-size: 13px;
  color: var(--cr-secondary-text-color);
  font-weight: 500;
}

.debug-row cr-input {
  flex: 1;
  margin-bottom: 0;
  --cr-input-error-display: none;
}

.current-host-display {
  flex: 1;
  font-family: monospace;
  font-size: 13px;
  padding: 8px 12px;
  background-color: var(--cr-hover-background-color);
  border-radius: 4px;
  border: 1px solid var(--cr-separator-color);
  word-break: break-all;
}

/* Eligibility Tab */
.eligibility-section {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.eligibility-status {
  padding: 16px;
  border-radius: 8px;
  font-size: 18px;
  font-weight: 600;
  text-align: center;
}

.eligibility-status.eligible {
  background-color: rgba(52, 168, 83, 0.1);
  color: rgb(24, 128, 56);
  border: 1px solid rgba(52, 168, 83, 0.3);
}

.eligibility-status.ineligible {
  background-color: rgba(234, 67, 53, 0.1);
  color: rgb(197, 34, 31);
  border: 1px solid rgba(234, 67, 53, 0.3);
}

@media (prefers-color-scheme: dark) {
  .eligibility-status.eligible {
    background-color: rgba(129, 201, 149, 0.15);
    color: rgb(129, 201, 149);
    border-color: rgba(129, 201, 149, 0.3);
  }

  .eligibility-status.ineligible {
    background-color: rgba(242, 139, 130, 0.15);
    color: rgb(242, 139, 130);
    border-color: rgba(242, 139, 130, 0.3);
  }
}

.eligibility-reasons h3 {
  font-size: 14px;
  margin-top: 0;
  margin-bottom: 8px;
  color: var(--cr-primary-text-color);
}

.eligibility-reasons ul {
  list-style: disc;
  padding-left: 20px;
}

.eligibility-reasons li {
  padding: 4px 0;
  border: none;
  font-size: 13px;
}

.eligibility-reasons li:hover {
  background-color: transparent;
}`]);
}
