/* Link colour for every page that does not load scripts/_typography.css -
   i.e. everything outside Auth.Master: the 18 NotAuth.Master pages, LogIn and
   LogOut. Bootstrap's <a> rule reads these variables; before the custom build
   dropped Reboot, Bootstrap supplied both the rule and a colour of its own.
   Same values _typography.css uses, so the two agree. */
:root {
  --bs-link-color: #447CFF;
  --bs-link-hover-color: rgb(106, 150, 255);
}

.progress-container {
  position: relative;
}

.progress-container progress {
  opacity: .4;
  height: 40px;
}

.progress-container progress::-webkit-progress-bar {
  opacity: .4;
}

.progress-container progress::-webkit-progress-value {
  background-color: red;
}

.progress-container .progress-label {
  position: absolute;
  top: 3px;
  margin: 0;
  left: 525px;
  font-size: 22px;
}

i.fa-info-circle {
  color: white
}

@font-face {
  font-family: Exan-Regular;
  src: url(../fonts/Exan-Regular.ttf);
}

@font-face {
  font-family: Orbitron-Regular;
  src: url(../fonts/Orbitron-Regular.ttf);
}

@font-face {
  font-family: Orbitron-Regular;
  font-weight: 500;
  src: url(../fonts/Orbitron-Bold.ttf);
}

@font-face {
  font-family: Exo-Regular;
  font-weight: 900;
  src: url(../fonts/Exo-Regular.ttf);
}

html,
body {
  min-height: -webkit-fill-available;
}

::-webkit-scrollbar {
  width: 10px;
}

/* Track */
::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.8);
}

/* Handle */
::-webkit-scrollbar-thumb {
  background: rgba(27, 52, 105, 0.7);
  border-radius: 10px;
}

/* Handle on hover */
::-webkit-scrollbar-thumb:hover {
  background: #555;
}

[role="button"] {
  cursor: pointer;
}

[data-bs-toggle="popover"] {
  cursor: pointer;
}

.result_unsuccessful {
  display: none;
}

body {
  position: relative;
  min-height: 100vh;
  margin: 0;
  color: white;
  display: flex;
  flex-direction: column;
  /* flex-wrap: wrap;
  */

  background: linear-gradient(rgba(0, 0, 0, 0.65), rgba(0, 0, 0, 0.55)), url("../scripts/img/background-main.webp") no-repeat top center / cover fixed;
  font-family: Verdana;
}

h1,
h2,
h3,
h4,
h5 {
  font-family: Orbitron-Regular;
}

.big-title {
  font-family: Orbitron-Regular;
  font-weight: bold;
  font-size: 24px;
  line-height: 28px;
}

body:after {
  background-color: #222;
  height: auto;
  min-height: 100vh;
  width: 100vw;
  opacity: 0.7;

  position: fixed;
  content: "";
  z-index: -2;
}

/* items that need to wait for VUE to load on page */
.wait-for-load {
  opacity: 0;
}

.small-col {
  min-width: 70px;
  width: 2% !important;
}

.gap-3 {
  gap: .75rem !important;
}

.flex-grow {
  flex-grow: 1;
}

.justify-center {
  justify-content: center;
}

.ml-auto {
  margin-left: auto;
}

.mr-auto {
  margin-right: auto;
}

.mr-2 {
  margin-right: 8px;
}

/* notification */
#money-notif,
#land-notif,
#newbie-notif {
  display: none;
}

#newbie-notif.show-notif {
  transform: translateY(0);
}

#rewards-notif.show-notif {
  transform: translateX(0);
}

.newbie-available {
  display: none;
}

#money-notif,
#land-notif,
#newbie-notif {
  display: none;
}

#newbie-notif.show-notif {
  transform: translateY(0);
}

#rewards-notif {
  position: fixed;
  padding: 15px;
  border: 1px solid white;
  background: rgba(27, 52, 105, 0.7);
  color: #fff;
  max-width: 500px;
  margin: 0 auto 15px;
  right: 0;
  transform: translateX(100%);
  top: 10vh;
  transition: 0.5s;
  z-index: 9999;
}

#newbie-notif i {
  font-size: 20px;
}

#newbie-notif {
  position: fixed;
  padding: 15px;
  border: 1px solid white;
  background: rgba(105, 27, 57, 1);
  color: #fff;
  max-width: 500px;
  min-width: 320px;
  margin: 0 auto 15px;
  left: 0;
  right: 0;
  transform: translateY(calc(-100% - 15px));
  top: 15px;
  transition: 0.5s;
  font-size: 15px;
  z-index: 99999;
}

#newbie-notif i {
  font-size: 20px;
}

#newbie-notif {
  position: fixed;
  padding: 15px;
  border: 1px solid white;
  background: rgba(105, 27, 57, 1);
  color: #fff;
  max-width: 500px;
  min-width: 320px;
  margin: 0 auto 15px;
  left: 0;
  right: 0;
  transform: translateY(calc(-100% - 15px));
  top: 15px;
  transition: 0.5s;
  font-size: 15px;
  z-index: 99999;
}

#rewards-notif i {
  position: absolute;
  top: -1px;
  right: -1px;
  color: #fff;
  cursor: pointer;
  font-size: 20px;
}

#go-top {
  display: none;
  position: fixed;
  bottom: 60px;
  z-index: 999;
  font-size: 40px;
  right: 15px;
  cursor: pointer;
}

#go-top:hover {
  animation-name: goTop;
  animation-duration: 0.7s;
  animation-iteration-count: infinite;
}

@keyframes goTop {
  from {
    transform: translate(0, 0px);
  }

  65% {
    transform: translate(0, -10px);
  }

  to {
    transform: translate(0, 0px);
  }
}

a.no-styles {
  color: #fff;
  text-decoration: none;
}

a.sector-nw {
  text-decoration: underline;
}

.info {
  font-size: 12px;
  margin: 15px 0;
  display: block;
  font-style: italic;
  color: #79a7e8;
}

.top1,
a.top1.no-styles,
a.top1.sector-nw,
.sector-table .current a.top1,
.sector-table .sl a.top1 {
  color: #ad4dc5;
  font-weight: bold;
}


.justify-space-between {
  justify-content: space-between;
}

.top2,
a.top2.no-styles,
a.top2.sector-nw,
.sector-table .current a.top2,
.sector-table .sl a.top2 {
  color: #7957fb;
}

.top3,
a.top3.no-styles,
a.top3.sector-nw,
.sector-table .current a.top3,
.sector-table .sl a.top3 {
  color: #7e71f9;
}

.top4,
a.top4.no-styles,
a.top4.sector-nw,
.sector-table .current a.top4,
.sector-table .sl a.top4 {
  color: #7e8cf1;
}

.top5,
a.top5.no-styles,
a.top5.sector-nw,
.sector-table .current a.top5,
.sector-table .sl a.top5 {
  color: #79a7e8;
}

.top10,
a.top10.no-styles,
a.top10.sector-nw,
.sector-table .current a.top10,
.sector-table .sl a.top10 {
  color: #6ec2de;
}

.online {
  color: green;
}

.offline,
.dead {
  color: grey;
}

.dead a {
  pointer-events: none;
}

.unit-icon i.fa-user-astronaut,
.money-icon i {
  position: absolute;
  left: 3px;
  top: 50%;
  transform: translateY(-50%);
  width: 13px;
}

.unit-icon,
.money-icon {
  position: relative;
  padding-left: 15px !important;
}

.offense-block-row i.fa-user-astronaut {
  color: #ca4c4c;
}

.defense-block-row i.fa-user-astronaut {
  color: yellow;
}

.hybrid-block-row i.fa-user-astronaut {
  color: orange;
}

.fusion-block-row i.fa-user-astronaut {
  color: purple;
}

.sci-block-row i.fa-user-astronaut {
  color: #5a8ae2;
}

.current,
.sector-table .current a,
.current.newbie,
.sector-table .current.newbie a {
  color: orange;
}

.current,
.sector-table .current a {
  color: orange;
}

.sl,
.sector-table .sl a {
  color: yellow;
}

.inactive,
.sector-table .inactive a {
  color: #cc9966;
}

.newbie,
.sector-table .newbie a {
  color: #00aaee;
}

.vacation,
.sector-table .vacation a {
  color: #1bb91b;
}

button.navbar-toggler {
  min-width: auto !important;
}

select {
  height: 35px;
  padding: 0 5px;
}

.align-center {
  text-align: center;
}

p#militaryinfo {
  border-radius: 5px;
}

.status-page .right-col {
  flex-direction: column;
  display: flex;
  justify-content: space-between;
}

main {
  flex: 1 1 100%;
  margin-top: 0;
  flex-grow: 1;
}

pre {
  color: #fff;
}

h1 {
  font-size: 26px;
  line-height: 30px;
}

h2 {
  font-size: 22px;
  line-height: 26px;
}

h3 {
  font-size: 20px;
  line-height: 24px;
}

h4 {
  font-size: 16px;
  line-height: 20px;
}

.custom-order-3 {
  order: 3;
}

.custom-order-2 {
  order: 2;
}

.custom-order-1 {
  order: 1;
}

.custom-order-first {
  order: first;
}

.custom-order-last {
  order: last;
}

input:focus,
select:focus {
  outline: none;
}

input:not([type="submit"]) {
  border: 1px solid transparent;
}

input:not([type="submit"]):focus {
  border: 1px solid #447cff;
}

h4.table-head {
  border: 1px solid rgba(0, 0, 0, 0.7);
  background: rgba(255, 255, 255, 0.3);
  margin-bottom: 0;
  box-sizing: border-box;
  padding: 10px 0;
}

select,
select option {
  border-color: rgba(27, 52, 105, 0.7);
  background: rgba(0, 0, 0, 1);
  color: #fff;
}

input[type="number"],
input[type="text"],
input[type="password"],
textarea {
  border-color: rgba(27, 52, 105, 0.7);
  background: rgba(255, 255, 255, 1);
  color: black;
}


.designed-select {
  background-color: rgba(15, 23, 42, 0.8) !important;
  background-image: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 4 5'%3E%3Cpath fill='%23cbd5e1' d='M2 0L0 2h4zm0 5L0 3h4z'/%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 0.75rem center !important;
  background-size: 8px 10px !important;
  color: #e2e8f0 !important;
  border: 1px solid rgba(68, 124, 255, 0.3) !important;
  border-radius: 8px !important;
  padding: 10px 14px !important;
  padding-right: 2.5rem !important;
  /* Make sure text doesn't overlap the arrow */
  height: auto !important;
  font-size: 12px !important;
  font-weight: 500 !important;
  outline: none !important;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1) !important;
  cursor: pointer !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  appearance: none !important;
  /* Remove native OS arrow */
  min-width: 160px;

  transition: all 0.3s ease !important;
}

.designed-select:focus {
  border-color: rgba(68, 124, 255, 0.6) !important;
  box-shadow: 0 0 10px rgba(68, 124, 255, 0.25) !important;
}

.designed-select option {
  background-color: #0f172a !important;
  color: #e2e8f0 !important;
}

table.reset-table {
  border: none;
  background: none;
}

table.reset-table td {
  border: none;
}

table.reset-table table {
  margin: 10px 0;
}

input[type="number"],
.number {
  width: 80px;
  text-align: center;
}

.button-link {
  padding: 6px 10px;
  display: inline-block;
  margin-top: 20px;
  text-decoration: none !important;
  background: rgba(0, 0, 0, 0.5);
}

a:link.btn-primary {
  color: white
}

input[type="submit"]:not(.danger-btn),
input[type="button"]:not(.danger-btn),
button,
.button {
  background-color: rgba(27, 52, 105, 0.7);
  color: white !important;
  box-shadow: 0 4px 14px rgba(68, 124, 255, 0.35);
  width: auto;
  text-decoration: none !important;
  border-radius: 0;
  border: 1px solid rgba(255, 255, 255, 0.8);
  padding: 6px 10px;
  min-width: 160px;
  box-sizing: border-box;
  font-weight: 700 !important;
  outline-color: #586690;
  transition: 0.3s ease-out;
}

input[type="submit"].table-col-submit,
button.table-col-submit,
.button.table-col-submit {
  min-width: 72px;
}

.fa-exclamation-triangle {
  color: rgb(201, 4, 4) !important;
}

.fa-exclamation-triangle.text-warning {
  color: rgb(160, 144, 1) !important;
  font-size: 7px !important;
  vertical-align: middle
}



input[type="submit"].danger-btn,
button.danger-btn,
a.danger-btn {
  background-color: rgba(114, 0, 0, 0.7);
  color: white !important;
  text-decoration: none !important;
  border-radius: 0;
  border: 1px solid rgba(255, 255, 255, 0.8);
  padding: 6px 10px;
  min-width: 160px;
  box-sizing: border-box;
  font-weight: 700 !important;
  outline-color: #586690;
  transition: 0.3s ease-out;
  font-size: 13px;
}

input[type="submit"].danger-btn:hover {
  background-color: rgb(78, 0, 0);
}

.danger-btn:disabled {
  background: white;
}

input[type="submit"]:disabled,
input[type="button"]:disabled,
button:disabled,
.button:disabled {
  pointer-events: none;
  background-color: rgba(255, 255, 255, 0.8);
  color: black !important;
}

input[type="submit"]:disabled:hover,
input[type="button"]:disabled:hover,
button:disabled:hover,
.button:disabled:hover {
  background-color: rgba(255, 255, 255, 0.8);
  border-color: rgba(255, 255, 255, 0.8);
  color: black;
}

input[type="submit"]:hover,
input[type="button"]:hover,
button:hover,
button:focus,
.button:hover,
.button:focus {
  box-shadow: 0 6px 20px rgba(68, 124, 255, 0.5);
  transform: translateY(-1px);
}

.col-section {
  padding: 8px 15px;
  background: rgba(0, 0, 0, 0.8);
  margin-top: 15px;
}

.col-section.with-rows {
  padding-bottom: 0;
}

/* .sok-container div {
  padding: 5px 0;
}
*/
.heading-section {
  margin-bottom: 5px;
}

.heading-section h3 {
  margin-bottom: 0;
}

.heading-section h3+span {
  padding-left: 15px;
  color: #447cff;
  font-size: 13px;
}

.col-section.with-rows tr {
  height: 31px;
  border-bottom: 5px solid rgba(68, 124, 255, 0);
}

.col-section.with-rows td {
  border-right: 1px solid rgba(68, 124, 255, 0.5);
  border-top: 0;
  border-bottom: 0;
}

.col-section.with-rows .row {
  padding: 8px 0;
  border-bottom: 1px solid rgba(68, 124, 255, 0.5);
}

.separator {
  text-align: center;
  height: 30px;
  border-bottom: 1px solid rgba(68, 124, 255, 0.5);
  background: #00123e;
  padding: 5px 8px;
  box-sizing: border-box;
}

.separator a {
  color: white !important;
  font-size: 13px;
  text-decoration: underline;
}

.separator a:nth-child(2) {
  margin-right: 20px;
}

.separator a:hover {
  text-decoration: none;
}

.kingdom-chooser .col-section {
  background: rgba(0, 0, 0, 0.6);
}

.col-section-with-separator {
  border-right: 1px solid rgba(68, 124, 255, 0.5);
  border-bottom: 1px solid rgba(68, 124, 255, 0.5);
}

/* Bootstrap 5 compatibility.
   BS4's .row left its children alone. BS5 adds `.row > * { width: 100% }`,
   which is right for real col-* children and wrong for everything else - any
   other child now takes a full row to itself and the group stacks vertically.
   These two classes only look like columns; they are page furniture that sized
   to its content under BS4 (the five-links bars on Status, the section blocks).

   The note that used to sit here said "Specificity here is 0,2,0 against
   Bootstrap's 0,1,0, so genuine col-* classes are unaffected regardless of load
   order." That is exactly backwards - 0,2,0 BEATS 0,1,0 - and it cost a page. An
   element carrying both, e.g.

       class="col-section col-sm-12 col-md-8 offset-md-2"

   lost its width cap entirely: flex: 0 0 auto with width: auto and nothing
   capping it, so the column sized to its widest child and dragged the row with
   it, while offset-md-2 kept its 16.667% margin. That was NewbieMode.aspx, and
   it took #912, #913, #915, #916 and the sk- migration in #917 to settle.

   So the rule now refuses to match an element that is also a real column. The
   :not() list is the Bootstrap 5 column vocabulary:

     [class~="col"]          bare .col
     [class*="col-auto"]     .col-auto and the per-breakpoint autos
     [class*="col-{bp}-"]    .col-sm-6, .col-md-8, ...
     [class*="col-{1..9}"]   .col-1 through .col-12 - the 1 prefix covers 10-12

   Wrapped in :where() so it contributes nothing, and the classes sit inside
   :is() whose specificity is that of its most specific argument. The selector
   therefore still weighs exactly 0,2,0, so nothing changes about how it applies
   to genuine furniture - it simply stops applying to things that are not. The
   <=1100px width rules further down still win by coming later.

   This changes no page today: the only markup pairing col-section with real
   column classes is the "Find out more" box on Default.aspx / DefaultS2.aspx,
   whose parent is a .col and not a .row, so this selector never reached it. The
   guard is here to stop the collision happening again. */
.row > :is(.col-section, .col-section-semi-transparent, .pref-submit-btn):not(:where(
    [class~="col"],
    [class*="col-auto"],
    [class*="col-sm-"],
    [class*="col-md-"],
    [class*="col-lg-"],
    [class*="col-xl-"],
    [class*="col-xxl-"],
    [class*="col-1"],
    [class*="col-2"],
    [class*="col-3"],
    [class*="col-4"],
    [class*="col-5"],
    [class*="col-6"],
    [class*="col-7"],
    [class*="col-8"],
    [class*="col-9"]
  )) {
  width: auto;
  max-width: none;
}

/* Same rule also forces a gutter:
     .row > * { padding-right: calc(var(--bs-gutter-x) * .5); padding-left: ... }
   at 0,1,1, which outranks a class's own padding. BS4 padded only real col-*
   children, so restoring BS4 means putting each element's own value back.

   .col-section-semi-transparent declares no padding at all, so it takes zero -
   the gutter was filling its translucent background and reading as a taller
   box than the button beside it (visible on Modules, on a row that already
   sets its own gap). .col-section keeps the 8px 15px it declares. */
.row > .col-section-semi-transparent {
  padding-right: 0;
  padding-left: 0;
}

.row > .col-section {
  padding: 8px 15px;
}

.col-section-semi-transparent {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
}

.col-section i {
  margin-right: 5px;
  color: #447cff;
}

footer,
.footer {
  background: rgba(0, 0, 0, 0.8);
  text-align: center;
}

footer:not(.inside-footer) {
  padding: 15px 0;
  font-size: 12px;
  margin-top: 15px;
}

table.day-table td {
  vertical-align: middle;
}

table.day-table tr {
  height: 30px;
  background: rgba(0, 0, 0, 0.8);
}

table.day-table {
  background-color: transparent !important;
  border-collapse: initial !important;
  border: 0 !important;
}

table.day-table tr:first-child {
  background: rgba(0, 0, 0, 0.3);
}

table.som-table td {
  vertical-align: middle;
}

table.som-table tr td {
  height: 30px;
  background: rgba(0, 0, 0, 0.8);
}

table.som-table {
  background-color: transparent !important;
  border-collapse: initial !important;
  border: 0 !important;
}

span.small {
  font-size: 10px;
}

table.som-table tr:not(:first-child) td:first-child {
  background: rgba(0, 0, 0, 0.3);
}

table.som-table tr:first-child td {
  background: rgba(0, 0, 0, 0.3);
}

.relative {
  position: relative;
}

.button.cancel-btn {
  background-color: white;
  color: black !important;
  border-color: #447cff;
}

/* reset loader used on confirmation modals */
#reset-loader {
  height: 100vh;
  width: 100vw;
  background: black;
  position: fixed;
  top: 0;
  z-index: 9999;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  display: none;
  left: 0;
}

#reset-loader h2 {
  font-size: 20px;
}

body.show-loading #reset-loader {
  display: flex;
  z-index: 99999;
}

#reset-loader .loading-wrapper {
  width: 300px;
  height: 150px;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.loading-wrapper::before,
.loading-wrapper::after {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  animation: clipMeWide 1s linear infinite;
  content: "";
  z-index: -1;
  margin: -1%;
  box-shadow: inset 0 0 0 2px #007bff;
}

.loading-wrapper::before {
  animation-delay: -1s;
}

@keyframes clipMeWide {

  0%,
  100% {
    clip: rect(0px, 360px, 2px, 0px);
  }

  25% {
    clip: rect(0px, 2px, 165px, 0px);
  }

  50% {
    clip: rect(160px, 360px, 165px, 0px);
  }

  75% {
    clip: rect(0px, 360px, 165px, 160px);
  }
}

.confirmation-modal a.button,
.confirmation-modal input[type="submit"].danger-btn {
  max-width: 100px;
  font-size: 13px;
  padding: 5px;
  min-width: 100px;
}

.confirmation-modal .button-wrapper {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-around;
  margin-top: 10px;
}

.confirmation-modal {
  background: black;
  padding: 30px;
  border: 1px solid white;
  position: absolute;
  top: 0;
  transform: translateX(-50%) translateY(calc(-100% - 5px));
  left: 50%;
  transition: all 0.3s ease;
  z-index: 9999;
  opacity: 0;
}

.confirmation-modal.active {
  opacity: 1;
}

.slide-fade-enter-active {
  transition: all 0.4s ease;
  opacity: 1;
}

.slide-fade-leave-active {
  transition: all 0.4s cubic-bezier(1, 0.5, 0.8, 1);
}

.slide-fade-enter {
  transform: translateY(0) translateX(-50%);
  opacity: 1;
}

.slide-fade-leave-to {
  transform: translateY(0) translateX(-50%);
  opacity: 0;
}

table.action-table tr:not(.mobile-actions-row) {
  height: 31px;
  background: rgba(0, 0, 0, 0.8);
}

table.action-table.with-padding td {
  padding-left: 6px;
  padding-top: 6px;
}

table.action-table.with-padding-y td {
  padding-bottom: 6px;
  padding-top: 6px;
}

table.action-table tr td {
  vertical-align: middle;
}

table.action-table {
  background-color: transparent !important;
  border-collapse: initial !important;
  border: 0 !important;
}


table.action-table tbody:first-child tr:first-child,
table.action-table tbody:first-child tr:first-child th {
  background: rgba(0, 0, 0, 0.3);
}

/* Members roster table (Alliance Control roles tab) - glassmorphic surface/accent matching
   .pref-card. Shared: Alliance Standings, per-alliance Players breakdown, Mine Gold panels. */
.members-table {
  width: 100%;
  border-collapse: collapse;
  background: rgba(15, 23, 42, 0.5);
  border: 1px solid rgba(68, 124, 255, 0.15);
  border-radius: 8px;
  overflow: hidden;
}

.members-table th,
.members-table td {
  padding: 10px 14px;
  text-align: center;
  border-bottom: 1px solid rgba(68, 124, 255, 0.15);
  color: #f8fafc;
}

.members-table tr:last-child td {
  border-bottom: 0;
}

.members-table tr:not(:first-child):hover td {
  background: rgba(68, 124, 255, 0.08);
}

/* table.members-table beats _table.css's bare "th { background-color: rgb(66,66,66) }" defensively
   (specificity already favors the class selector, but !important removes any doubt) and the
   opacity is bumped from a barely-there 0.12 so the blue tint doesn't read as plain grey. */
table.members-table th {
  background: rgba(68, 124, 255, 0.18) !important;
  color: #94a3b8 !important;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 700;
}

.members-table td:first-child,
.members-table th:first-child {
  text-align: left;
}

.members-table input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: #447CFF;
  cursor: pointer;
}

.blue-transparent-bck {
  background: rgba(68, 124, 255, 0.4);
}

.semi-transparent-bck,
table.semi-transparent-bck {
  background-color: rgba(0, 0, 0, 0.6);
  border-collapse: initial !important;
  border: 0 !important;
}

.semi-transparent-bck,
table.semi-transparent-bck.with-border-color td {
  border-color: rgba(68, 124, 255, 0.5);
  padding: 5px;
}

.transparent-bck,
table.transparent-bck {
  background-color: transparent;
}

table.transparent-bck.with-border-color td {
  border-color: rgba(68, 124, 255, 0.5);
}

#ContentPlaceHolder1_lblError {
  color: red;
}

/* icons */
body .fa-bolt {
  color: #9e9e14;
}

body .fa-dollar-sign {
  color: #6bc06b;
}

body .fa-coins {
  color: gold;
}

body .fa-user-astronaut {
  color: #6bc06b;
}

body .fa-globe {
  color: #447cff;
}

body .fa-chart-line {
  color: #7ec7f3;
}

body .fa-clock {
  color: #fff;
}

body .fa-radiation-alt {
  color: #9e9e14;
}

body .fa-robot {
  color: #447cff;
}

body .fa-campground {
  color: #447cff;
}

body .fa-atom {
  color: #206BDF
}

.top-icon {
  display: none;
}

.top-icon i {
  padding: 10px;
  border-radius: 50%;
  background: black;
}

/* .top-icon.explore i {
  padding: 10px 8px;
  transform: rotate(-90deg);
}
*/
.row-hover tr {
  transition: 0.3s ease-out;
  text-align: center;
}

.row-hover tr:not(:first-child):hover {
  background: rgba(68, 124, 255, 0.2);
}

/* tooltip and popover */

[data-bs-toggle="popover"] {
  cursor: pointer;
}

.popover {
  max-width: 300px;
  border-radius: 5px;
  background: rgba(16, 56, 148, 1);
}

.popover .popover-body a {
  color: white;
  text-decoration: underline;
}

.popover.show {
  opacity: 1;
}

.bs-popover-top .popover-arrow::after,
.bs-popover-auto[data-popper-placement^=top] .popover-arrow::after {
  border-top-color: rgba(16, 56, 148, 1);
}

.bs-popover-start .popover-arrow::after,
.bs-popover-auto[data-popper-placement^=left] .popover-arrow::after {
  border-left-color: rgba(16, 56, 148, 1);
}

.bs-popover-bottom .popover-arrow::after,
.bs-popover-auto[data-popper-placement^=bottom] .popover-arrow::after {
  border-bottom-color: rgba(16, 56, 148, 1);
}

.bs-popover-end .popover-arrow::after,
.bs-popover-auto[data-popper-placement^=right] .popover-arrow::after {
  border-right-color: rgba(16, 56, 148, 1);
}

[data-bs-toggle="tooltip"] {
  cursor: pointer;
}

.tooltip .tooltip-inner {
  max-width: 300px;
  background: rgba(16, 56, 148, 1);
}

.tooltip.show {
  opacity: 1;
}

.bs-tooltip-top .tooltip-arrow::before,
.bs-tooltip-auto[data-popper-placement^=top] .tooltip-arrow::before {
  border-top-color: rgba(16, 56, 148, 1);
}

.bs-tooltip-start .tooltip-arrow::before,
.bs-tooltip-auto[data-popper-placement^=left] .tooltip-arrow::before {
  border-left-color: rgba(16, 56, 148, 1);
}

.bs-tooltip-bottom .tooltip-arrow::before,
.bs-tooltip-auto[data-popper-placement^=bottom] .tooltip-arrow::before {
  border-bottom-color: rgba(16, 56, 148, 1);
}

.bs-tooltip-end .tooltip-arrow::before,
.bs-tooltip-auto[data-popper-placement^=right] .tooltip-arrow::before {
  border-right-color: rgba(16, 56, 148, 1);
}

.buildings-tooltip.tooltip .tooltip-inner {
  max-width: 300px;
  background: black;
  color: white;
  border: 1px solid rgba(16, 56, 148, 1);
}

.buildings-tooltip.bs-tooltip-top .tooltip-arrow::before,
.buildings-tooltip.bs-tooltip-auto[data-popper-placement^=top] .tooltip-arrow::before {
  border-top-color: black;
}

.buildings-tooltip.bs-tooltip-start .tooltip-arrow::before,
.buildings-tooltip.bs-tooltip-auto[data-popper-placement^=left] .tooltip-arrow::before {
  border-left-color: black;
}

.buildings-tooltip.bs-tooltip-bottom .tooltip-arrow::before,
.buildings-tooltip.bs-tooltip-auto[data-popper-placement^=bottom] .tooltip-arrow::before {
  border-bottom-color: black;
}

.buildings-tooltip.bs-tooltip-end .tooltip-arrow::before,
.buildings-tooltip.bs-tooltip-auto[data-popper-placement^=right] .tooltip-arrow::before {
  border-right-color: black;
}

/* bottom links */
.bottom-links {
  margin: 15px 0 30px;
}

.bottom-links a {
  padding: 6px 10px;
  display: block;
  width: 100%;
  text-decoration: none;
}

.bottom-links .col-section-semi-transparent,
.button-link {
  min-width: 150px;
  position: relative;
  z-index: 2;
  border: 1px solid rgba(68, 124, 255, 0.2);
}

.bottom-links .col-section-semi-transparent:after,
.bottom-links .col-section-semi-transparent:before,
.button-link:before,
.button-link:after {
  z-index: -1;
}

.bottom-links .col-section-semi-transparent:after,
.bottom-links .col-section-semi-transparent:before,
.button-link:before,
.button-link:after,
.scores-list a:after,
.scores-list a:before {
  left: 0;
  content: "";
  position: absolute;
  top: 0;
  width: 100%;
  height: 100%;
  border-style: solid;
  border-color: white;
  transition: 0.3s;
}

.bottom-links .col-section-semi-transparent:after,
.button-link:after,
.scores-list a:after {
  border-width: 0 1px 0 1px;
  transform: scaleY(0);
}

.bottom-links .col-section-semi-transparent:before,
.button-link:before,
.scores-list a:before {
  border-width: 1px 0 1px 0;
  transform: scaleX(0);
}

.bottom-links .col-section-semi-transparent:hover:after,
.bottom-links .col-section-semi-transparent:hover:before,
.button-link:hover:before,
.button-link:hover:after,
.scores-list a:hover:before,
.scores-list a:hover:after {
  transform: scale(1, 1);
}

.bottom-links .col-section-semi-transparent:hover,
.bottom-links .col-section-semi-transparent:hover,
.button-link:hover,
.button-link:hover,
.scores-list a:hover {
  background: black;
}

table input {
  height: 35px;
}

.kingdom-chooser input[type="text"],
.change-sector-column input[type="number"] {
  text-align: center;
  height: 37px !important;
  width: 45px !important;
  padding: 8px 0 !important;
}

.kingdom-chooser select {
  max-width: 100% !important;
  width: 300px !important;
}

/* checkbox */
.chkbox-col input {
  display: none;
}

.chkbox-col {
  padding: 5px;
}

.probe-result {
  overflow-x: auto;
}

.chkbox-col label {
  display: flex;
  cursor: pointer;
  align-items: center;
  margin-bottom: 0;
}

.chkbox-col .check-mark {
  width: 5px;
  height: 10px;
  height: 10px;
  border: solid white;
  border-width: 0 2px 2px 0;
  -webkit-transform: rotate(45deg) scale(0);
  -ms-transform: rotate(45deg) scale(0);
  transform: rotate(45deg) scale(0);
  position: absolute;
  transition: 0.3s;
  left: 5px;
  top: 2px;
}

.chkbox-col .dummy-checkbox {
  cursor: pointer;
  width: 18px;
  height: 18px;
  border: 1px solid #fff;
  margin-right: 15px;
  position: relative;
}

.chkbox-col input:checked+.dummy-checkbox:before {
  opacity: 1;
}

.chkbox-col input:checked+.dummy-checkbox .check-mark {
  -webkit-transform: rotate(45deg) scale(1);
  -ms-transform: rotate(45deg) scale(1);
  transform: rotate(45deg) scale(1);
  opacity: 1;
}

.chkbox-col .dummy-checkbox:before {
  height: 100%;
  width: 100%;
  position: absolute;
  transition: 0.3s;
  content: "";
  background: rgba(27, 52, 105, 1);
  opacity: 0;
  left: 0;
  top: 0;
  z-index: 0;
}

.danger {
  color: #ff9900;
}

.almost {
  color: #fbc97d;
}

.over,
.under {
  color: green;
}



/* Bootstrap 5 compatibility.

   BS5 colours every table cell:
     .table > :not(caption) > * > *  { color: var(--bs-table-color...) }
   at specificity 0,1,1 - which outranks a single class like .over (0,1,0)
   sitting on the same <td>. BS4 never set a cell colour, so these worked.

   Two classes is 0,2,0 and takes it back, with no !important and without
   touching the base rules above. Any other colour class that lands on a cell
   and loses the same way belongs here. */
.table .over,
.table .under {
  color: green;
}

.table .almost {
  color: #fbc97d;
}

.table .error {
  color: #ff6f6f;
}

.table .danger {
  color: #ff9900;
}

.error {
  color: #ff6f6f;
}

.hidden {
  opacity: 0;
}

#page-message,
.page-message {
  padding: 10px;
  background: rgba(0, 0, 0, 0.5);
  display: none;
}



.page-message {
  margin-bottom: 5px;
}

.alliance-menu-title {
  padding: 5px 0;
  border-bottom: 1px solid rgba(68, 124, 255, 0.3);
  text-align: center;
  display: inline-block;
  font-family: Orbitron-Regular;
}

#disband-table input {
  width: 80px;
}

/* block separator */
table.action-table tr.block-separator {
  background: rgba(68, 124, 255, 0.6);
}

table.action-table tr.block-separator:hover {
  background: rgba(68, 124, 255, 0.6);
}

.max-icon-link {
  font-size: 20px;
}

table.action-table#disband-table tr.block-separator {
  background: rgba(255, 137, 137, 0.5);
}

table.action-table#disband-table tr.block-separator:hover {
  background: rgba(255, 137, 137, 0.5);
}

/* add tick modal */
.add-tick-confirmation-modal {
  display: none;
  position: absolute;
  bottom: 30px;
  width: 318px;
  left: 0;
  right: 0;
  margin: 0 auto;
  background: black;
  padding: 15px;
  border: 1px solid white;
  opacity: 0;
  transform: translateY(0%);
  z-index: 9999;
}

.add-tick-confirmation-modal a.button {
  max-width: 100px;
  font-size: 13px;
  padding: 5px;
  min-width: 100px;
}

.add-tick-confirmation-modal a.button.modal-accept {
  margin: 5px 0 15px;
  display: block;
  width: 100%;
  max-width: none;
}

.add-tick-confirmation-modal.show {
  display: block;
  animation-name: goDown;
  animation-duration: 0.5s;
  animation-delay: 0.2s;
  animation-fill-mode: forwards;
}

@keyframes goDown {
  0% {
    opacity: 0;
  }

  100% {
    opacity: 1;
    transform: translateY(100%);
  }
}

/* add tick modal */

.add-tick-confirmation-modal {
  display: none;
  position: absolute;
  bottom: 30px;
  width: 318px;
  left: 0;
  right: 0;
  margin: 0 auto;
  background: black;
  padding: 15px;
  border: 1px solid white;
  opacity: 0;
  transform: translateY(0%);
  z-index: 9999;
}

.add-tick-confirmation-modal a.button {
  max-width: 100px;
  font-size: 13px;
  padding: 5px;
  min-width: 100px;
}

.add-tick-confirmation-modal a.button.modal-accept {
  margin: 5px 0 15px;
  display: block;
  width: 100%;
  max-width: none;
}

.add-tick-confirmation-modal.show {
  display: block;
  animation-name: goDown;
  animation-duration: 0.5s;
  animation-delay: 0.2s;
  animation-fill-mode: forwards;
}

.mobilisation {
  color: darkred;
}

.growth {
  color: darkgreen;
}

.offensive {
  color: palegreen !important;
}

.defensive {
  color: aqua;
}

.research {
  color: yellow;
}

@keyframes goDown {
  0% {
    opacity: 0;
  }

  100% {
    opacity: 1;
    transform: translateY(100%);
  }
}

@media only screen and (max-width: 992px) {
  h1 {
    font-size: 20px;
    line-height: 24px;
  }

  h2 {
    font-size: 18px;
    line-height: 22px;
  }

  h3 {
    font-size: 16px;
    line-height: 20px;
  }

  h4 {
    font-size: 13px;
    line-height: 15px;
  }

  body {
    font-size: 12px;
  }

  .separator a {
    font-size: 11px;
  }

  .sector-table a,
  table {
    font-size: 11px;
  }
}

@media only screen and (max-width: 768px) {
  .rewards-notif {
    max-width: 300px;
  }

  .mobile-column {
    flex-direction: column;
  }

  .tooltip:not(.buildings-tooltip) {
    display: none !important;
  }

  .kingdom-chooser input[type="text"],
  .change-sector-column input[type="text"] {
    height: 35px !important;
    width: 100px !important;
  }

  .tooltip .tooltip-inner {
    font-size: 13px;
  }

  h1 {
    font-size: 18px;
    line-height: 22px;
  }

  h2 {
    font-size: 16px;
    line-height: 20px;
  }

  h3 {
    font-size: 15px;
    line-height: 18px;
  }

  body {
    font-size: 12px;
  }

  input,
  select {
    font-size: 12px !important;
  }

  body:after {
    min-height: calc(100vh + 120px);
  }
}

/*.five-links .col-section-semi-transparent {
    width: 20%;
    flex: 0 0 20%;
    max-width: 20%;
    margin-top: 10px;
}

.five-links .col-section-semi-transparent:nth-child(3),
.five-links .col-section-semi-transparent:last-child {
    margin-left: 0 !important;
}
*/
/*.bottom-links .col-section-semi-transparent {
    margin: 5px 0 0 !important;
}*/

@media (max-width: 1100px) {
  .five-links .col-section-semi-transparent {
    width: 25%;
    flex: 0 0 25%;
    max-width: 25%;
    margin-top: 10px;
  }
}

@media (max-width: 900px) {
  .five-links .col-section-semi-transparent {
    width: 33%;
    flex: 0 0 33%;
    max-width: 33%;
    margin-top: 10px;
  }

  .five-links .col-section-semi-transparent:nth-child(3),
  .five-links .col-section-semi-transparent:last-child {
    margin-left: 0 !important;
  }
}

@media (max-width: 700px) {
  .four-links .col-section-semi-transparent:last-child {
    margin-top: 10px;
    margin-left: 0 !important;
  }

  .four-links .col-section-semi-transparent:nth-child(3) {
    margin-top: 10px;
    margin-left: 0 !important;
    margin-right: 8px;
  }

  .tooltip .tooltip-inner {
    font-size: 10px;
  }

  .top-info-bar+.container,
  .top-info-bar+.container-fluid:not(.view-sector) {
    padding: 0 !important;
  }
}

@media (max-width: 640px) {
  .hide-mobile {
    display: none !important;
  }

  h1 {
    font-size: 20px;
    line-height: 24px;
  }

  .mobile-display-none {
    display: none;
  }

  h2 {
    font-size: 18px;
    line-height: 22px;
  }

  h3 {
    font-size: 15px;
    line-height: 18px;
  }

  h4 {
    font-size: 13px;
    line-height: 15px;
  }

  h5 {
    font-size: 13px;
    line-height: 15px;
  }

  .big-title {

    font-size: 14px;
    line-height: 16px;
  }


  body table td {
    font-size: 10px;
  }

  .sector-table a,
  table {
    font-size: 10px;
  }
}

@media (max-width: 420px) {
  body table td {
    font-size: 9px;
  }

  body table td a {
    font-size: 9px;
  }

  .sector-table a,
  table {
    font-size: 9px;
  }

  #military-table i,
  #soldiers-table i,
  #disband-table i {
    display: none;
  }
}

@media (max-width: 368px) {
  .five-links .col-section-semi-transparent {
    width: 50%;
    flex: 0 0 50%;
    max-width: 50%;
  }

  .bottom-links .col-section-semi-transparent {
    margin: 5px 0 0 !important;
  }
}

/* Responsive layout for six-links */
@media (max-width: 1100px) {
  .six-links .col-section-semi-transparent {
    width: 20%;
    flex: 0 0 20%;
    max-width: 20%;
    margin-top: 10px;
  }
}

@media (max-width: 900px) {
  .six-links .col-section-semi-transparent {
    width: 33%;
    flex: 0 0 33%;
    max-width: 33%;
    margin-top: 10px;
  }

  .six-links .col-section-semi-transparent:nth-child(3),
  .six-links .col-section-semi-transparent:last-child {
    margin-left: 0 !important;
  }
}

@media (max-width: 368px) {
  .six-links .col-section-semi-transparent {
    width: 50%;
    flex: 0 0 50%;
    max-width: 50%;
  }
}

@media (max-width: 340px) {
  body table td {
    font-size: 8px;
  }

  body table td a {
    font-size: 8px;
  }

  .sector-table a,
  table {
    font-size: 8px;
  }
}

/* Toast */

/* Toast Notification styles */
.toast-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.custom-toast {
  min-width: 250px;
  background: rgba(15, 23, 42, 0.9);
  backdrop-filter: blur(8px);
  border-radius: 8px;
  padding: 12px 16px;
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  gap: 12px;
  transform: translateY(-20px);
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.custom-toast.show {
  transform: translateY(0);
  opacity: 1;
}

.custom-toast.success {
  border-left: 4px solid #22c55e;
}

.custom-toast.error {
  border-left: 4px solid #ef4444;
}

.custom-toast i {
  font-size: 1.25rem;
}

.custom-toast.success i {
  color: #22c55e;
}

.custom-toast.error i {
  color: #ef4444;
}

/* Toggle Switch Styles */
.switch {
  position: relative;
  display: inline-block;
  width: 46px;
  height: 22px;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(255, 255, 255, 0.1);
  transition: .3s;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.slider:before {
  position: absolute;
  content: "";
  height: 14px;
  width: 14px;
  left: 3px;
  bottom: 3px;
  background-color: #bbbbbb;
  transition: .3s;
  border-radius: 50%;
}

.switch input:checked~.slider {
  background-color: rgba(68, 124, 255, 0.4);
  border-color: rgba(68, 124, 255, 0.8);
}

.switch input:checked~.slider:before {
  background-color: #447cff;
  transform: translateX(24px);
}

/* Current Tick Badge styling */
.current-tick-badge {
  background: rgba(68, 124, 255, 0.15) !important;
  border: 1px solid rgba(68, 124, 255, 0.3) !important;
  color: #fff !important;
  padding: 3px 8px !important;
  border-radius: 6px !important;
  font-size: 13px !important;

  white-space: nowrap !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 3px;
  box-shadow: 0 0 10px rgba(68, 124, 255, 0.1) !important;
  text-shadow: 0 0 5px rgba(255, 255, 255, 0.3) !important;
}

.current-tick-badge i {
  color: #447CFF !important;
}

/* Designed Dropdown components to match designed-select style */
.designed-dropdown-trigger {
  background: rgba(15, 23, 42, 0.8) !important;
  color: #e2e8f0 !important;
  border: 1px solid rgba(68, 124, 255, 0.3) !important;
  border-radius: 8px !important;
  padding: 10px 14px !important;
  height: auto !important;
  font-size: 14px !important;
  font-weight: 500 !important;
  outline: none !important;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1) !important;
  cursor: pointer !important;
  transition: all 0.3s ease !important;
}

.designed-dropdown-trigger:focus,
.designed-dropdown-trigger.active {
  border-color: rgba(68, 124, 255, 0.6) !important;
  box-shadow: 0 0 10px rgba(68, 124, 255, 0.25) !important;
}

.designed-dropdown-panel {
  position: absolute;
  top: 105%;
  left: 0;
  z-index: 1000;
  background: #0f172a !important;
  border: 1px solid rgba(68, 124, 255, 0.4) !important;
  border-radius: 8px !important;
  max-height: 250px;
  overflow-y: auto;
  min-width: 250px;
  padding: 6px 0 !important;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.4), 0 0 15px rgba(68, 124, 255, 0.1) !important;
}

.designed-dropdown-item {
  padding: 8px 14px !important;
  cursor: pointer !important;
  font-size: 0.9rem !important;
  display: flex !important;
  align-items: center !important;
  color: #cbd5e1 !important;
  transition: background 0.2s ease, color 0.2s ease;
}

.designed-dropdown-item:hover {
  background: rgba(68, 124, 255, 0.1) !important;
  color: #fff !important;
}

/* Alliance Info Redesign Styles */
.alliance-stats-row {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 15px;
  margin-bottom: 20px;
}

.stat-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(15, 23, 42, 0.55);
  border: 1px solid rgba(68, 124, 255, 0.25);
  border-radius: 20px;
  padding: 8px 16px;
  font-size: 14px;
  color: #cbd5e1;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  transition: all 0.2s ease;
}

.stat-pill:hover {
  border-color: rgba(68, 124, 255, 0.4);
  background: rgba(15, 23, 42, 0.7);
  transform: translateY(-1px);
}

.stat-pill i {
  font-size: 13px;
}

.stat-pill strong {
  color: #fff;
  font-weight: 700;
}

.gold-pill i {
  color: #eab308;
}

.info-pill i {
  color: #3b82f6;
}

.primary-pill i {
  color: #06b6d4;
}

.success-pill i {
  color: #10b981;
}

.relic-pill i {
  color: #a855f7;
}



.relations-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: #e2e8f0;
}

/* Compact Diplomatic Panel */
.diplo-panel {
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(68, 124, 255, 0.2);
  border-radius: 12px;
  padding: 10px 14px;
  margin-top: 14px;
  margin-bottom: 4px;
}

.diplo-header {
  font-size: 0.8rem;
  font-weight: 700;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.diplo-header i {
  color: #3b82f6;
  font-size: 12px;
}

.diplo-groups {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.diplo-group {
  flex: 1;
  min-width: 130px;
  background: rgba(30, 41, 59, 0.4);
  border-radius: 8px;
  padding: 7px 10px;
  border-left: 3px solid transparent;
}

.diplo-war {
  border-left-color: #ef4444;
}

.diplo-peace {
  border-left-color: #10b981;
}

.diplo-pact {
  border-left-color: #06b6d4;
}

.diplo-group-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 5px;
  display: flex;
  align-items: center;
  gap: 5px;
}

.diplo-war .diplo-group-label {
  color: #f87171;
}

.diplo-peace .diplo-group-label {
  color: #34d399;
}

.diplo-pact .diplo-group-label {
  color: #22d3ee;
}

.diplo-fields {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.diplo-field {
  display: flex;
  align-items: baseline;
  gap: 5px;
  flex-wrap: wrap;
}

.diplo-field-label {
  font-size: 0.65rem;
  color: #64748b;
  white-space: nowrap;
  width: 60%;
  text-align: left;
}

.diplo-field-label::after {
  content: ':';
}

.diplo-field-value {
  font-size: 0.72rem;
  color: #cbd5e1;
  flex: 1;
}

/* Chips inside diplo-field-value (alliance names rendered as <a> tags) */
.diplo-war .diplo-field-value a {
  display: inline-flex;
  align-items: center;
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 0.7rem;
  font-weight: 600;
  margin: 1px;
  text-decoration: none !important;
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #fca5a5 !important;
}

.diplo-peace .diplo-field-value a {
  display: inline-flex;
  align-items: center;
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 0.7rem;
  font-weight: 600;
  margin: 1px;
  text-decoration: none !important;
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #6ee7b7 !important;
}

.diplo-pact .diplo-field-value a {
  display: inline-flex;
  align-items: center;
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 0.7rem;
  font-weight: 600;
  margin: 1px;
  text-decoration: none !important;
  background: rgba(6, 182, 212, 0.08);
  border: 1px solid rgba(6, 182, 212, 0.3);
  color: #67e8f9 !important;
}

@media (max-width: 480px) {
  .diplo-groups {
    flex-direction: column;
  }

  .diplo-group {
    min-width: unset;
    width: 100%;
  }
}


.relations-dashboard {
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(68, 124, 255, 0.2);
  border-radius: 16px;
  padding: 20px;
  margin-top: 20px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
  text-align: left;
}

.relations-dashboard-header {
  font-size: 1.15rem;
  font-weight: 700;
  color: #e2e8f0;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding-bottom: 12px;
}

.relations-dashboard-header i {
  color: #3b82f6;
}

.relation-row-item {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 6px;
  background: rgba(30, 41, 59, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.03);
  border-radius: 12px;
  margin-bottom: 8px;
  transition: all 0.3s ease;
}

.relation-row-item:last-child {
  margin-bottom: 0;
}

.relation-row-item:hover {
  background: rgba(30, 41, 59, 0.35);
  border-color: rgba(68, 124, 255, 0.15);
}

.row-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 200px;
  flex-shrink: 0;
}

.row-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  font-size: 16px;
}

.row-details {
  display: flex;
  flex-direction: column;
}

.row-title {
  font-size: 0.9rem;
  font-weight: 700;
  color: #f1f5f9;
}

.row-subtitle {
  font-size: 0.72rem;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.row-content-fields {
  display: flex;
  flex-grow: 1;
  gap: 20px;
}

.relation-field {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.field-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: #94a3b8;
}

.field-value {
  color: #64748b;
  font-size: 0.85rem;
  font-style: italic;
}

/* Category Accent Styles */
.war-row {
  border-left: 4px solid #ef4444;
}

.war-row .row-icon {
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.2);
  color: #ef4444;
}

.peace-row {
  border-left: 4px solid #10b981;
}

.peace-row .row-icon {
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.2);
  color: #10b981;
}

.treaty-row {
  border-left: 4px solid #06b6d4;
}

.treaty-row .row-icon {
  background: rgba(6, 182, 212, 0.1);
  border: 1px solid rgba(6, 182, 212, 0.2);
  color: #06b6d4;
}

/* Custom Chip styles for relations inside .field-value */
.field-value a {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  margin: 2px;
  transition: all 0.2s ease;
  text-decoration: none !important;
}

.war-row .field-value a {
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #fca5a5 !important;
}

.war-row .field-value a:hover {
  background: rgba(239, 68, 68, 0.25);
  border-color: rgba(239, 68, 68, 0.6);
  color: #fff !important;
  transform: translateY(-1px);
}

.peace-row .field-value a {
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #6ee7b7 !important;
}

.peace-row .field-value a:hover {
  background: rgba(16, 185, 129, 0.25);
  border-color: rgba(16, 185, 129, 0.6);
  color: #fff !important;
  transform: translateY(-1px);
}

.treaty-row .field-value a {
  background: rgba(6, 182, 212, 0.08);
  border: 1px solid rgba(6, 182, 212, 0.3);
  color: #67e8f9 !important;
}

.treaty-row .field-value a:hover {
  background: rgba(6, 182, 212, 0.25);
  border-color: rgba(6, 182, 212, 0.6);
  color: #fff !important;
  transform: translateY(-1px);
}

/* Mobile & Tablet Scaling Rules */
@media (max-width: 992px) {
  .relation-row-item {
    gap: 15px;
    padding: 12px;
  }

  .row-meta {
    width: 170px;
  }
}

@media (max-width: 768px) {
  .alliance-stats-row {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
    margin-top: 10px !important;
    margin-bottom: 12px !important;
  }

  .stat-pill {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    padding: 6px 10px !important;
    font-size: 10px !important;
    border-radius: 12px !important;
    width: 100% !important;
  }

  .stat-pill i {
    font-size: 9px !important;
  }

  .relations-dashboard {
    padding: 12px !important;
    margin-top: 15px !important;
    border-radius: 12px !important;
  }

  .relations-dashboard-header {
    font-size: 1rem !important;
    margin-bottom: 12px !important;
    padding-bottom: 8px !important;
  }

  .relation-row-item {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 12px !important;
    border-radius: 10px !important;
  }

  .row-meta {
    width: 100% !important;
  }

  .row-icon {
    width: 32px !important;
    height: 32px !important;
    font-size: 14px !important;
    border-radius: 8px !important;
  }

  .row-title {
    font-size: 0.85rem !important;
  }

  .row-subtitle {
    font-size: 0.68rem !important;
  }

  .row-content-fields {
    width: 100% !important;
    flex-direction: column !important;
    gap: 10px !important;
  }

  .relation-field {
    width: 100% !important;
  }

  .field-label {
    font-size: 0.68rem !important;
  }

  .field-value {
    font-size: 0.78rem !important;
  }

  .field-value a {
    padding: 2px 6px !important;
    font-size: 0.75rem !important;
    border-radius: 4px !important;
  }

  /* Enhancements & Negative Effects mobile columns */
  .mobile-column {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
    padding: 4px !important;
  }

  .mobile-column>div {
    display: inline-flex !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 6px 8px !important;
    border-radius: 8px !important;
    justify-content: space-between !important;
    align-items: center !important;
    box-sizing: border-box !important;
    min-height: 26px !important;
  }

  .mobile-column>div>span {
    font-size: 10px !important;
  }

  .mobile-column>div>span:first-child {
    font-size: 10px !important;
    margin-right: 4px !important;
    font-weight: bold !important;
  }
}

@media (max-width: 480px) {
  .alliance-stats-row {
    gap: 6px !important;
  }

  .stat-pill {
    padding: 5px 8px !important;
    font-size: 9px !important;
  }
}


/* NEW DESIGN */
/* TODO : change name of the classname to something more generic */

/* Glassmorphic Preference Panel Card */
.pref-card {
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(68, 124, 255, 0.15);
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 24px;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  animation: fadeIn 0.4s ease-in-out;
}

.pref-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(68, 124, 255, 0.12);
  border: 1px solid rgba(68, 124, 255, 0.35);
  color: #fff !important;
  border-radius: 7px;
  padding: 7px 12px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none !important;
  transition: all 0.2s ease;
  white-space: nowrap;
  width: 120px;
  min-width: auto;
  justify-content: center;
}

.pref-btn:hover {
  background: rgba(68, 124, 255, 0.25);
  color: #fff;
  border-color: rgba(68, 124, 255, 0.6);
  transform: translateY(-1px);
}

.pref-btn.danger {
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.pref-btn.danger:hover {
  background: rgba(239, 68, 68, 0.25);
  border-color: rgba(239, 68, 68, 0.6);
}

.pref-btn.success {
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.pref-btn.success:hover {
  background: rgba(16, 185, 129, 0.25);
  border-color: rgba(16, 185, 129, 0.6);
}

.pref-btn.icon {
  width: 35px;
  padding: 5px;
}

.pref-btn.icon i {
  margin-right: 0;
}

.pref-card-inner {
  /* Subtle, darker fill to create depth inside pref-card */
  background: rgba(2, 6, 23, 0.45);

  /* Delicate border using bright sci-fi accent color */
  border: 1px solid rgba(56, 189, 248, 0.12);
  border-radius: 10px;
  padding: 18px 20px;

  /* Inset shadow gives it a "recessed screen" feel */
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.05),
    0 4px 12px rgba(0, 0, 0, 0.25);

  /* Smooth transition for hover effects */
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.pref-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid rgba(68, 124, 255, 0.15);
  padding-bottom: 12px;
  margin-bottom: 20px;
}

.pref-card-header h4,
.pref-card-header h5 {
  margin: 0;
  font-weight: 600;
  letter-spacing: 0.5px;
  color: #f8fafc;
}

.pref-card-header i {
  color: #447CFF;
  font-size: 1.3rem;
}

/* Tab Container Styling */
.pref-tabs-wrapper {
  background-color: rgba(10, 15, 30, 0.95);
  /* More solid background wrapper */
  border: 1px solid rgba(68, 124, 255, 0.25);
  border-radius: 8px;
  padding: 6px;
  margin-bottom: 25px;
}

.pref-tabs {
  display: flex;
  flex-wrap: wrap;
  overflow-x: auto;
  scrollbar-width: none;
  gap: 8px;
}

.pref-tabs::-webkit-scrollbar {
  display: none;
}

.pref-tabs .tab-btn {
  background-color: rgba(15, 23, 42, 0.6);
  /* More solid background for individual tabs */
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 6px;
  color: #94a3b8;
  padding: 8px 14px;
  font-size: 0.82rem;
  /* Smaller text on desktop */
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  outline: none;
  min-width: auto;
  flex: 1;
}

.pref-tabs .tab-btn:hover {
  color: #f8fafc;
  background-color: rgba(68, 124, 255, 0.15);
  border-color: rgba(68, 124, 255, 0.3);
}

.pref-tabs .tab-btn.active {
  color: #ffffff !important;
  /* Extremely clear active state - white text */
  background: linear-gradient(135deg, rgba(68, 124, 255, 0.4) 0%, rgba(30, 64, 175, 0.5) 100%) !important;
  /* Highlight background */
  border: 1px solid rgba(68, 124, 255, 0.8) !important;
  font-weight: 600;
  box-shadow: 0 0 10px rgba(68, 124, 255, 0.3);
}

/* Mobile responsive tab buttons */
@media (max-width: 768px) {
  .pref-tabs .tab-btn {
    font-size: 0.72rem;
    /* Even smaller text on Mobile */
    padding: 6px 10px;
    gap: 5px;
    min-width: calc(50% - 8px) !important;
    /* 2 on a row on mobile */
    flex: 1 1 calc(50% - 8px);
  }
}

/* Custom Styled Select Dropdown (Mobile-first fallback) */
.pref-select-wrapper {
  margin-bottom: 20px;
}

.pref-select {
  background-color: #0f172a;
  border: 1px solid rgba(68, 124, 255, 0.25);
  color: #f8fafc;
  padding: 10px 14px;
  border-radius: 8px;
  width: 100%;
}

.pref-select:focus {
  outline: none;
  border-color: #447CFF;
  box-shadow: 0 0 0 2px rgba(68, 124, 255, 0.2);
}

.pref-card-form {
  width: 100%;
}

/* 3-Column Layout Row */
.form-group-row {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  padding: 14px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  width: 100%;
  gap: 12px;
}

.form-group-row:last-of-type {
  border-bottom: none;
}

.form-label-col {
  flex: 1;

  font-size: 0.95rem;
  color: #cbd5e1;
  display: flex;
  flex-direction: column;
  text-align: left;
  border: none;
  background: transparent;
  padding: 0;
}

.form-label-col .label-subtitle {
  font-size: 0.8rem;
  color: #787f88;
  margin-top: 4px;
  font-weight: normal;
}

.form-status-col {
  flex: 0 0 45%;
  width: 45%;
  max-width: 45%;
  display: flex;
  justify-content: center;
  align-items: center;
  border: none;
  background: transparent;
  padding: 0;
}

.form-control-col {
  flex: 0 0 calc(20% - 24px);
  width: calc(20% - 24px);
  max-width: calc(20% - 24px);
  display: flex;
  justify-content: flex-end;
  align-items: center;
  border: none;
  background: transparent;
  padding: 0;
}

.form-control-col-center {
  flex: 1 1 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  border: none;
  background: transparent;
  padding: 10px 0 0 0;
}

/* Text Inputs, Dropdowns */
.pref-card input[type="text"],
.pref-card input[type="number"],
.pref-card input[type="password"],
.pref-card select {
  background-color: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(68, 124, 255, 0.2);
  color: #ffffff;
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 0.9rem;
  width: 100%;
  max-width: 240px;
  transition: all 0.3s ease;
}

.pref-card input[type="text"]:focus,
.pref-card input[type="number"]:focus,
.pref-card input[type="password"]:focus,
.pref-card select:focus {
  border-color: #447CFF;
  box-shadow: 0 0 8px rgba(68, 124, 255, 0.2);
  outline: none;
}

/* Custom Checkbox as Switch Button */
.pref-card .checkbox {
  display: flex;
  align-items: center;
  position: relative;
  padding-left: 55px;
  min-height: 24px;
  cursor: pointer;
  font-size: 0.95rem;
  color: #cbd5e1;
  user-select: none;
  margin: 6px 0;
  text-align: left;
}

.pref-card .checkbox input[type="checkbox"] {
  position: absolute;
  left: 0;
  top: 1px;
  width: 44px;
  height: 22px;
  opacity: 0;
  z-index: 2;
  cursor: pointer;
  margin: 0;
}

/* The toggle switch background */
.pref-card .checkbox label::before {
  content: '';
  position: absolute;
  left: 0;
  top: 1px;
  width: 44px;
  height: 22px;
  background-color: rgba(148, 163, 184, 0.3);
  border-radius: 100px;
  transition: background-color 0.2s ease-in-out;
}

/* The toggle switch knob */
.pref-card .checkbox label::after {
  content: '';
  position: absolute;
  top: 4px;
  left: 3px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background-color: white;
  transition: transform 0.2s ease-in-out;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

/* State when checked */
.pref-card .checkbox input[type="checkbox"]:checked+label::before {
  background-color: #22c55e;
}

.pref-card .checkbox input[type="checkbox"]:checked+label::after {
  transform: translateX(22px);
}


.kingdom-chooser-wrapper {
  flex-direction: row;
}

/* Responsive Overrides */
@media (max-width: 768px) {
  .kingdom-chooser-wrapper {
    flex-direction: column;
    align-items: center;
  }

  .kingdom-chooser-wrapper input {
    width: 100% !important;
  }

  .pref-card {
    padding: 16px;
  }

  .form-group-row {
    gap: 8px;
  }

  .form-label-col {
    font-size: 0.62rem;
  }

  .percent-indicator-block {
    font-size: 0.52rem;
    padding: 4px;
  }

  .pref-card input[type="text"],
  .pref-card input[type="number"],
  .pref-card input[type="password"],
  .pref-card select {
    max-width: 100%;
    padding: 6px 8px;
    font-size: 0.8rem;
  }

  .form-status-col {
    flex: 0 0 35%;
    max-width: 35%;
  }

  .form-control-col {
    flex: 0 0 30%;
    max-width: 30%;
  }

  /* Military Unit Rows on Mobile */
  .form-group-row.military-unit-row {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .form-group-row.military-unit-row .form-label-col {
    flex: 1 1 100%;
    width: 100%;
    min-width: 0;
    font-size: 0.85rem;
  }

  .form-group-row.military-unit-row .military-unit-controls {
    flex: 1 1 100%;
    width: 100%;
    justify-content: space-between;
    gap: 10px;
  }

  .form-group-row.military-unit-row .military-unit-controls select {
    flex: 1 1 auto;
    min-width: 0;
    max-width: none;
  }

  .form-group-row.military-unit-row .military-unit-controls input[type="number"] {
    flex: 0 0 85px;
    width: 85px;
    max-width: 85px;
  }

  /* Delete Account Row on Mobile */
  .form-group-row.delete-account-row {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .form-group-row.delete-account-row .form-label-col {
    flex: 1 1 100%;
    width: 100%;
    min-width: 0;
    font-size: 0.85rem;
  }

  .form-group-row.delete-account-row .delete-account-controls {
    flex: 1 1 100%;
    width: 100%;
    justify-content: space-between;
    gap: 10px;
  }

  .form-group-row.delete-account-row .delete-account-controls input[type="password"] {
    flex: 1 1 auto;
    min-width: 0;
    max-width: none;
  }

  .form-group-row.delete-account-row .delete-account-controls .pref-submit-btn {
    white-space: nowrap;
  }
}