body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f9f9f9;
    color: #333;
}

h2, h3 {
    color: #2c3e50;
}

/* Landing Page Logo */
#landing-logo {
    text-align: center;
    margin-top: 200px;
    margin-bottom: 20px;
}

.logo-img {
    width: 550px;
    max-width: 100%;
}

.logo-col {
  position: static !important;   /* sovrascrive la regola bootstrap */
}

body { 
  position: relative;  
}

#results-logo {
    position: absolute;
    top: 20px;
    right: 10px; /* move logo */
    z-index: 999;
}

.logo-small {
    width: 170px;
    max-width: 100%;
}

/* Landing page search bar */
#landing-search {
    display: flex;
    flex-direction: column;
    align-items: center
}

#search-examples {
  font-family: Tahoma, sans-serif;
  color: #1b578d;
  margin-top: 12px;
  text-align: left;
  width: 100%;
  max-width: 290px;
  margin-left: auto;
  margin-right: auto;
}

#search-examples h4 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 6px;
  color: #1b578d;
}

#search-examples ul {
  list-style: disc inside;
  padding: 0;
  margin: 0;
}

#search-examples li {
  margin-bottom: 4px;
}

/* Results page search bar */
#results-search {
    width: 200px;
    margin: 10px 0 0 0;          /* Top margin, aligned left */
    text-align: left;
}

/* Align title on the left e separate it from table */
#results-header {
  text-align: left;
  margin: 10px 0 10px 0;
  width: 100%;       
}

#gene-title {
    margin-top: 30px;
    color: #1b578d;    /* Color */
    font-size: 28px;
    font-weight: bold;
}

/* constraint table and left list */
.constraint-container {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  margin-top: 20px;
}

/* Container right panel */
.constraint-right-panel {
  flex: 1;
}

/* Title on table right panel */
.constraint-title {
  font-size: 20px;
  font-weight: bold;
  color: #2c3e50;
  margin-bottom: 15px;
  margin-top: 0;
}

/* Table constraint */
.constraint-table {
  width: 100%;
  border-collapse: collapse;
  background-color: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  border: 1px solid #e0e0e0;
}

.constraint-table th {
  background-color: #5e99ab;
  color: white;
  padding: 12px 15px;
  text-align: left;
  font-weight: 600;
  border-bottom: 2px solid #4a7c8a;
}

.constraint-table td {
  padding: 10px 15px;
  border-bottom: 1px solid #f0f0f0;
  vertical-align: top;
}

.constraint-table tr:last-child td {
  border-bottom: none;
}

.constraint-table tr:hover {
  background-color: #f8f9fa;
}

/* Rows styles */
.constraint-table tr:nth-child(1) td:first-child {
  border-left: 4px solid #5cb85c; /* Green Synonymous */
}

.constraint-table tr:nth-child(2) td:first-child {
  border-left: 4px solid #f0ad4e; /* Orange Missense */
}

.constraint-table tr:nth-child(3) td:first-child {
  border-left: 4px solid #d9534f; /* Red pLoF */
}

/* Left list panel */
.gene-info-table {
  background-color: #fff;
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  border: 1px solid #e0e0e0;
}

.gene-info-table li {
  margin-bottom: 8px;
  padding: 5px 0;
  border-bottom: 1px solid #f0f0f0;
}

.gene-info-table li:last-child {
  border-bottom: none;
}

/* Responsive design */
@media (max-width: 768px) {
  .constraint-container {
    flex-direction: column;
    gap: 15px;
  }
  
  .constraint-table {
    font-size: 14px;
  }
  
  .constraint-table th,
  .constraint-table td {
    padding: 8px 10px;
  }
}

/* Horizontal line under (hr) */
#results-header hr {
  border: none;
  border-top: 2px solid #ccc;
  margin: 8px 0 0 0;
  width: 100%;    /* All container length occupied */
}

/*  Base: hide cell, draw square  */
.shiny-modal .checkboxGroupInput .checkbox input[type="checkbox"],
.shiny-modal .checkboxGroupInput .checkbox-inline input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

/* label “checkbox box” */
.shiny-modal .checkboxGroupInput .checkbox label,
.shiny-modal .checkboxGroupInput .checkbox-inline label {
  position: relative;
  padding-left: 1.8em;  
  margin-right: 1em;
  /* background white */
  background-color: #fff;
  border: 2px solid currentColor;
  border-radius: 4px;
  cursor: pointer;
  line-height: 1.8em;
  display: inline-block;
  min-width: 6em;      
  color: inherit;
}

/* Square: pseudo-elemento before */
.shiny-modal .checkboxGroupInput .checkbox label::before,
.shiny-modal .checkboxGroupInput .checkbox-inline label::before {
  content: "";
  position: absolute;
  left: 0.2em;
  top: 0.2em;
  width: 1.2em;
  height: 1.2em;
  background-color: #fff;     
  border: 2px solid currentColor;
  border-radius: 3px;
}

/* When checked, background colored */
.shiny-modal .checkboxGroupInput .checkbox input[type="checkbox"]:checked + label::before,
.shiny-modal .checkboxGroupInput .checkbox-inline input[type="checkbox"]:checked + label::before {
  background-color: currentColor;
  color: #fff;
  content: "\2713";  /* ✔ */
  font-size: 1em;
  text-align: center;
  line-height: 1.2em;
}

/* color */
.shiny-modal .checkboxGroupInput .checkbox label {
  opacity: 0.65;
}
.shiny-modal .checkboxGroupInput .checkbox input[type="checkbox"]:checked + label {
  opacity: 1;
}

/* Text input styling */
input[type="text"] {
    width: 100%;
    padding: 10px;
    border-radius: 8px;
    border: 1px solid #ccc;
    box-sizing: border-box;
    margin-bottom: 5px;          /* Space input and button */
}

/* Button styles */
.custom-btn {
    background-color: #5e99ab !important;
    color: #fff !important;
    border-radius: 8px !important;
    padding: 10px 20px !important;
    font-size: 16px !important;
    border: none !important;
    cursor: pointer !important;
    display: inline-block !important;
    margin-top: 5px !important;  
    transition: background-color 0.2s ease, transform 0.1s ease;
}

/* Hover effect */
.custom-btn:hover {
    background-color: #1b578d !important;
}

/* Focus effect for accessibility */
.custom-btn:focus {
    outline: 2px solid #1b578d !important;
    box-shadow: 0 0 6px rgba(0, 123, 255, 0.6) !important;
}

/* Click (active) effect */
.custom-btn:active {
    transform: scale(0.97);
    background-color: #004a99 !important;
}

.text-danger {
    display: block;
    margin-top: 10px;
    font-size: 16px;
    color: #d9534f; /* Bootstrap danger color */
}

/* Bullet dots */
.impact-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-right: 6px;
  vertical-align: middle;
}

.impact-HIGH     { background-color: #d9534f; }
.impact-MODERATE { background-color: #f0ad4e; }
.impact-LOW      { background-color: #5cb85c; }
.impact-MODIFIER { background-color: #5bc0de; }

/* fixed layout */
table.dataTable,
.dataTables_scrollHeadInner table,
.dataTables_scrollBody table {
  table-layout: fixed !important;
  width:        100%   !important;
}

table.dataTable th,
table.dataTable td {
  text-align:    left    !important;
  padding:       8px      !important;
  width:         140px    !important;
  max-width:     140px    !important;
  overflow:      hidden   !important;
  text-overflow: ellipsis!important;
  white-space:   nowrap   !important;
  cursor:        help     !important; 
}

/* Wrapper with horizontal scroll */
.dataTables_wrapper {
  overflow-x: auto;
  margin:     0 auto 20px auto;
  border:     1px solid #ccc;
  padding:    10px;
  background: #fff;
  border-radius: 8px;
}
