/* Layout */
.wsc-patents-controls {
  margin-bottom: 8px;
}
.wsc-patents-indicator-group .wsc-radio {
  display: block;
  margin: 6px 0 0 !important;
  font-size: 1rem;
}
.wsc-ctrl-label {
  display: block;
  margin-bottom: 10px;
  font-weight: 600;
}

/* +20px spacing above the slider as requested */
.wsc-year-slider-group {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 30px;
  font-size: 1rem;
}
.wsc-year-slider-wrap {
  position: relative;
  flex: 1;
}
.wsc-year-slider {
  width: 100%;
}
.wsc-year-tooltip {
  position: absolute;
  top: -26px;
  transform: translateX(-50%);
  background: #333;
  color: #fff;
  font-size: 12px;
  padding: 2px 6px;
  border-radius: 3px;
  pointer-events: none;
  white-space: nowrap;
}

/* Charts */
.wsc-world-chart-wrap {
  height: 275px;
  margin-top: 6px;
}
.wsc-patents-chart-wrap {
  height: 275px;
  margin-top: 10px;
}

/* Search */
input.wsc-patents-search {
  display: block;
  width: 100%;
  max-width: 100%;
  margin: 15px 0 15px;
  padding: 8px !important;
  border: 1px solid #ddd;
  border-radius: 5px !important;
  font-size: 1em;
  box-sizing: border-box;
}

/* Table wrapper (enables horizontal scroll on small viewports) */
.wsc-patents-table-wrap {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

/* Base table */
.wsc-patents-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: auto;        /* let the country column size to its content */
  min-width: 520px;          /* reasonable floor so columns don't crush */
}

/* Small-screen font size */
@media screen and (max-width: 600px) {
  .wsc-patents-table { font-size: 17px; }
}

/* Header */
.wsc-patents-table thead th {
  background-color: #f4f0f0;
  padding: 10px 8px;
  text-align: left;          /* left align headings */
  border-bottom: 1px solid #dcd9d9;
  white-space: nowrap;
}

/* Body cells */
.wsc-patents-table tbody td {
  padding: 10px 8px;
  border-bottom: 1px solid #ddd;
  vertical-align: middle;
  text-align: left;          /* left align body cells by default */
}

/* Rank column */
.wsc-patents-table thead th.rank,
.wsc-patents-table tbody td.rank {
  width: 64px;
  text-align: left;
  color: #333;
}

/* Year column */
.wsc-patents-table thead th.year,
.wsc-patents-table tbody td.year {
  text-align: left;
  white-space: nowrap;
}

/* Country column: keep name + flag on one line; allow table to grow horizontally */
.wsc-patents-table tbody td.country {
  white-space: nowrap;
}

/* Zebra striping */
.wsc-patents-table tbody tr:nth-child(odd) { background-color: #fff; }
.wsc-patents-table tbody tr:nth-child(even) { background-color: #f9f6f6; }

/* Loading row */
.wsc-patents-table .loading {
  text-align: center;
  padding: 18px;
  color: #666;
}

/* Flags */
.wsc-patents-table img.flag {
  width: 20px;
  height: auto;
  vertical-align: middle;
  margin-right: 0.5em;
  border-radius: 2px;
}

/* Optional sort icon appearance (⇵) */
.sort-icon { color: #999; }

/* Attribution */
.wsc-patents-attrib {
  color: #666;
  margin: 10px 0 0;
}
