#info-box {
  display: none;
  position: absolute;
  top: 0px;
  left: 0px;
  z-index: 999;
  background-color: #ffffff;
  border: 2px solid #bf0a30;
  border-radius: 5px;
  font-family: arial;
  min-width: 300px;
  text-align: center;
  border: none !important;
  box-shadow: 0px 0px 0px 3px #7c2354;
  -webkit-box-shadow: 0px 0px 0px 3px #7c2354;
  padding: 0 !important;
}

#info-box h5,
#info-box h6 {
  font-size: 16px;
  font-weight: 600;
}

#info-box #license_title,
#info-box #license_valid_till {
  text-align: left;
  padding: 0px 15px;
  margin-top: 15px;
}

#info-box #license_valid_till {
  margin-top: 15px;
}

#state_name {
  font-size: 22px !important;
  background: #000000ff;
  margin-top: 0;
  padding: 12.5px 15px;
  color: #fff;
  border-top-left-radius: 5px;
  border-top-right-radius: 5px;
}

#info-box #link {
  display: flex;
  width: 100%;
  overflow: hidden;
  padding-left: 15px;
  padding-right: 15px;
  padding-top: 15px;
  flex-direction: column;
  align-items: start;
}

#info-box #link i {
  margin-right: 10px;
}

#info-box #link a {
  background: #7c2354;
  padding: 8px 10px;
  display: inline-block;
  color: #fff;
  font-size: 16px;
  font-weight: 600;
  border-radius: 5px;
  margin-bottom: 15px;
  margin-right: 15px;
  width: 100%;
}

#info-box #link a:hover {
  background-color: #e56a16;
}

#info-box #link a:last-child {
  margin-right: 0;
  margin-bottom: 10px;
}

@media only screen and (max-width: 768px) {
  .rte {
    max-width: 90vw;
    overflow-x: auto;
  }

  #center_column {
    width: 100%;
  }
}

#cms #center_column img {
  margin: 4px 0px;
}

#container {
  min-height: 80vh;
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  overflow: visible;
  position: relative;
}

/* Default styles for all devices - keeping original size with horizontal scrolling */
.map-wrapper {
  display: block !important;
  overflow-x: auto !important;
  /* Force horizontal scrolling container */
  -webkit-overflow-scrolling: touch;
  /* Smooth scrolling on iOS */
  width: 100%;
}

.map-wrapper svg {
  width: auto !important;
  /* Allow SVG to be its natural width on mobile */
  height: auto !important;
  min-width: 900px;
  /* Set minimum width to ensure scrolling is possible */
  margin: 0 auto;
}

/* Scaling for desktop devices only */
@media only screen and (min-width: 992px) {
  .map-wrapper {
    overflow-x: visible !important;
  }

  .map-wrapper svg {
    width: 100% !important;
    min-width: auto;
    transform: scale(1.2);
    transform-origin: center top;
    max-width: 1400px;
  }

  #container {
    min-height: 70vh;
    overflow: visible;
  }
}

@media only screen and (min-width: 1400px) {
  .map-wrapper svg {
    transform: scale(1.2);
    max-width: 1600px;
  }

  #container {
    min-height: 80vh;
  }
}

#map-legend {
  display: flex;
  align-items: flex-end;
  flex-direction: column;
  padding: 15px 0px;
}

@media only screen and (max-width: 767.8px) {
  #map-legend {
    align-items: flex-start;
    padding: 15px 5px;
  }

  .map-legend-item {
    margin-bottom: 10px;
  }

  .map-legend-text {
    font-size: 12px;
    line-height: 14px !important;
  }
}

#map-legend .map-legend-color {
  width: 30px;
  height: 15px;
  background: #7c2354;
  border-radius: 4px;
  margin-right: 10px;
}

.map-legend-text {
  margin-bottom: 0px;
}

#map-legend .map-legend-item {
  display: flex;
  align-items: center;
}

#map-legend .map-legend-simple {
  width: 30px;
  height: 15px;
  background: rgb(211, 211, 211);
  border-radius: 4px;
  margin-right: 10px;
}

.state-text {
  font-weight: bold;
  font-size: 16px !important;
}

.state-ak {
  transform: translate(10px, -20px);
}

.state-hi {
  transform: translate(42px, 20px);
  font-size: 8px !important;
}

.state-fl {
  transform: translate(40px, -20px);
}

.state-ca {
  transform: translate(-20px, 10px);
}

.state-la {
  transform: translate(-20px, 0);
}

.state-id {
  transform: translate(-10px, 30px);
}

.state-mi-up {
  transform: translate(0, -15px);
  font-size: 10px !important;
}

.state-mi-lp {
  transform: translate(25px, 30px);
}

.state-md {
  transform: translate(5px, -10px);
  font-size: 10px !important;
}

.state-dc {
  font-size: 0px !important;
}

.state-mn {
  transform: translate(-20px, 10px);
}

.state-nj {
  transform: translate(0px, -16px);
  font-size: 8px !important;
}

.state-de {
  transform: translate(3px, 8px);
  font-size: 5px !important;
}

.state-ny {
  transform: translate(0px, 5px);
}

.state-va {
  transform: translate(20px, 0px);
}

.state-ky {
  transform: translate(15px, 0px);
}

.state-wv {
  transform: translate(-5px, 0px);
}

.state-ct {
  transform: translate(0px, -5px);
  font-size: 8px !important;
}

.state-ma {
  transform: translate(-10px, -2px);
  font-size: 8px !important;
}

.state-ri {
  transform: translate(0px, -2px);
  font-size: 6px !important;
}

.state-vt {
  transform: translate(0px, -12px);
  font-size: 8px !important;
}

.state-nh {
  transform: translate(-2px, 15px);
  font-size: 10px !important;
}

/* rx-states table */

#state-license-table {
  position: relative;
  z-index: 2;
  background: #fff;
  clear: both;
  margin-bottom: 30px;
}

.state-license-table-title {
  font-size: 22px;
  font-weight: 600;
  margin: 0 0 15px;
}

.state-license-table-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

/* @media only screen and (min-width: 992px) {
  #container.map-wrapper {
    padding-bottom: calc(min(100vw, 1400px) * 1200 / 1300 * 0.2);
  }
}

@media only screen and (min-width: 1400px) {
  #container.map-wrapper {
    padding-bottom: calc(min(100vw, 1600px) * 1200 / 1300 * 0.2);
  }
} */

table.state-license-table {
  width: 100%;
  border-collapse: collapse;
  font-family: arial;
  font-size: 15px;
  min-width: 720px;
}

.state-license-table-caption {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

table.state-license-table thead th {
  background: #000000ff;
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  text-align: left;
  padding: 12.5px 15px;
  white-space: nowrap;
}

table.state-license-table thead th:first-child {
  border-top-left-radius: 5px;
}

table.state-license-table thead th:last-child {
  border-top-right-radius: 5px;
}

table.state-license-table tbody th,
table.state-license-table tbody td {
  padding: 10px 15px;
  border-bottom: 1px solid #e5e5e5;
  vertical-align: middle;
  text-align: left;
}

table.state-license-table tbody tr:nth-child(even) {
  background: #faf6f8;
}

table.state-license-table tbody tr:hover {
  background: #f3e7ee;
}

table.state-license-table tbody th[scope="row"] {
  font-weight: 600;
}

.state-license-iso {
  font-weight: 600;
  color: #7c2354;
  white-space: nowrap;
}

.state-license-empty {
  color: #999;
}

td.state-license-action {
  width: 1%;
  white-space: nowrap;
}

table.state-license-table td.state-license-action a.link {
  background: rgba(124, 35, 84, 0.15);
  padding: 8px 10px;
  display: inline-block;
  color: #7c2354;
  font-size: 14px;
  font-weight: 600;
  border-radius: 5px;
  text-decoration: none;
  white-space: nowrap;
  border: 1px solid #7c2354;
}

table.state-license-table td.state-license-action a.link:hover {
  background-color: #e56a16;
  color: #fff;
}

table.state-license-table td.state-license-action a.link i {
  margin-right: 8px;
}

/* Stack into cards on small screens so no horizontal scrolling is needed */
@media only screen and (max-width: 767.8px) {
  .state-license-table-scroll {
    overflow-x: visible;
  }

  table.state-license-table {
    min-width: 0;
    width: 100%;
    display: block;
  }

  table.state-license-table tbody {
    display: block;
    width: 100%;
  }

  table.state-license-table thead {
    display: none;
  }

  table.state-license-table tbody tr {
    display: block;
    margin-bottom: 20px;
    border: 0.1px solid rgba(124, 35, 84, 0.15);
    border-radius: 5px;
    overflow: hidden;
  }

  table.state-license-table tbody tr:nth-child(even),
  table.state-license-table tbody tr:hover {
    background: none;
  }

  table.state-license-table tbody th,
  table.state-license-table tbody td {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
    width: auto;
    border-bottom: 1px solid #e5e5e5;
    padding: 10px 15px;
  }

  table.state-license-table tbody th[scope="row"] {
    background: #7c2354;
    color: #fff;
    font-size: 18px;
  }

  table.state-license-table tbody td[data-label]::before {
    content: attr(data-label);
    font-weight: 600;
    color: #666;
    flex-shrink: 0;
  }

  table.state-license-table tbody th[scope="row"]::before,
  table.state-license-table tbody td.state-license-action::before {
    display: none;
  }

  table.state-license-table tbody td.state-license-action {
    display: block;
    border-bottom: none;
    padding-bottom: 0;
  }

  table.state-license-table tbody td.state-license-action:last-child {
    padding-bottom: 15px;
  }

  table.state-license-table td.state-license-action a.link {
    width: 100%;
    text-align: center;
  }
}
