.battlesContainer {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-evenly;
    padding: 15px 0;
}

.battleGrid {
    background-image: url(/img/bg4.png);
    width: 376px;
    box-shadow: 0px 5px 10px 0px rgb(0 0 0 / 77%);
    border-radius: 0.5em;
    transition: all ease 0.2s;
    cursor: pointer;
    margin: 0 0 25px 0;
    position: relative;
    border: 3px solid white;
    color: black;
    text-shadow: none;
}

.battleGrid:hover {
    transform: translateY(-5px);
    box-shadow: 0px 10px 20px 2px rgba(0, 0, 0, 0.25);
}

.battleHeader {
    font-size: 1.5em;
    min-height: 35px;
    white-space: nowrap;
    text-overflow: ellipsis;
    text-transform: uppercase;
    font-weight: 900;
    position: relative;
    justify-items: left;
    display: flex;
    align-items: center;
    padding: 5px;
    font-family: 'Open Sans',Arial;
    text-shadow: 0 0 1px #f2f2f2, 0 0 2px #f2f2f2, 0 0 2px #f2f2f2;
}

.battleHeader a {
    color: #222;
}

.battleHeader i {
    font-size: 1.5em;
}

.battleHeaderNameTitle {
    background-image: linear-gradient(90deg, transparent, #000a 20%, #000a 80%, transparent);
    color: #f2f2f2;
    content: attr(data-login);
    display: none;
    font-size: 18px;
    padding: 2px 8px;
    position: absolute;
    top: -24px;
    width: 64px;
}

.battleHeaderName:hover .battleHeaderNameTitle {
    display: block;
}

.battleFooterTimer {
    /*background-image: linear-gradient(90deg, transparent, #0008 10%, #0008 100%, transparent);*/
   /*color: #0ec201;*/
   /*text-shadow: 2px 2px 2px #000, 2px 3px 5px #000, -1px 1px 0 #0000, 1px 1px 0 #0000;*/
   align-self: center;
   /*height: 100%;*/
      font-size: 1.5em;
      white-space: nowrap;
      text-overflow: ellipsis;
      overflow: hidden;
      width: 100px;
      text-align: end;
  }

  .battleParticipants {
      width: 376px;
      height: 120px;
      position: relative;
  }

  .battleInformations {
      width: 100%;
      min-height: 35px;
      color: white;
      position: absolute;
      display: grid;
      grid-template-columns: 1fr 150px 1fr;
      bottom: 0;
  }
  
  .battleTotalDamage {
font-size: 17px;
  	font-weight: bold;
  	text-shadow: 0 0 2px black, 0 0 4px black;
  	align-self: end;
      background-color: rgba(0, 0, 0, 0.5);
      border-radius: 4px 4px 0 0;
  }
  
  .battleFooter {
      position: relative;
      display: grid;
      grid-template-columns: 1fr 150px 1fr;
      gap: 0.5em;
  }

  .battleFooter .battleFooterScore {
      justify-self: center;
      font-size: 1.5em;
      font-weight: 900;
      align-self: center;
  }

  .battleFlagBackground {
      /*width: 188px;*/
    width: 100%;
    height: 120px;
    box-shadow: inset 0 0 15px 3px black;
    background-size: cover;
    background-position: center;
    position: relative;
}

.battleAvatar {
    height: 48px;
    width: 48px;
    border-radius: 6px;
    box-shadow: 0 0 4px 1px black;
    position: absolute;
    left: 50%;
    top: 50%;
    -webkit-transform: translate(-50%, -50%);
    transform: translate(-50%, -50%);
}

.battleIcon {
    width: 30px;
    height: 30px;
}

.civilWarIcon {
    background-image: url("/img/eventIcons/civilWarIcon2.png");
}

button.btn-fight {
    position: relative;
    padding: 0.85em 4.5em !important;
    font: 1rem 'Open Sans',Arial,sans-serif;
    letter-spacing: 2px;
    text-transform: uppercase;
    font-weight: 900;
    color: #fff;
    background: linear-gradient(to bottom, #19b416 5%, #0d5608 100%);
    box-shadow: inset 0px -4px 2px 1px #054404, inset 0px 1px 4px 0px rgb(108 253 91) !important;
    border: none;
    border-radius: 6px;
    text-shadow: 0 5px 20px rgb(1 122 3 / 40%), 0 2px 2px rgb(0 0 0 / 40%);
    margin-top: -30px;
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
    outline: 3px solid black;
    filter: drop-shadow(0px 2px 3px black);
}

button.btn-fight:hover {
    background-image: radial-gradient(100% 75% at 50% 100%, #1eab0c 0%, #259225 100%);
    cursor: pointer;
}

button.btn-fight:active {
    color: #f9e3bf;
    box-shadow: inset 0px 0px 3px 3px #054404, inset 0px 1px 4px 0px rgb(255 197 197) !important;
}

.roundStatus .mainBar {
    border-top: 1px solid #161616;
    border-bottom: 1px solid #161616;
    box-shadow: 0 0 2px #0008;
    color: #f2f2f2;
    height: 40px;
    margin: 0;
    overflow: hidden;
    padding: 0;
    position: relative;
    text-shadow: 0px 0px 2px black, 0px 1px 2px black, 0px 1px 2px black;
}
.roundStatus .mainBar .defendersBar, .roundStatus .mainBar .attackersBar {
    box-shadow: 0px 4px 2px -2px #ffffff82 inset, 0px -4px 2px -2px #0008 inset;
    height: 100%;
    margin: 0;
    padding: 0;
    position: absolute;
    top: 0;
    transition: width 1s ease-in-out;
}
.roundStatus .mainBar .defendersBar {
    left: 0;
    border-right: 1px solid #161616;
}
.roundStatus .mainBar .attackersBar {
    right: 0;
    border-left: 1px solid #161616;
}
.crimsonBar .mainBar .defendersBar {
    background-color: #14a0dc;
    background-image: repeating-linear-gradient(120deg, transparent, transparent 3px, #128fc5 3px, #128fc5 6px);
    color: #fff;
}
.crimsonBar .mainBar {
    background-color: #dc143c;
    background-image: repeating-linear-gradient(120deg, transparent, transparent 3px, #c51236 3px, #c51236 6px);
    color: #fff;
}

.roundStatus .mainBar .defendersPercent, .roundStatus .mainBar .attackersPercent {
    font-size: 16px;
    font-weight: bold;
    padding: 2px 8px;
    position: absolute;
}
.roundStatus .mainBar .defendersPercent {
    left: 0;
    text-align: left;
}
.roundStatus .mainBar .attackersPercent {
    right: 0;
    text-align: right;
}

.changingColor {
    background: linear-gradient(to right, #b8860b 25%, #b8b10b 50%, #b8860b 75%);
    background-size: 200% auto;
    color: #b8860b;
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: textclip 1.5s linear infinite;
    text-shadow: none;
    font-size: 22px;
    filter: drop-shadow(0px 0px 3px black);
}

.flagTexture {
    background-image: url('/img/flags/500px/flagTexture4.png');
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
    width: 100%;
    height: 100%;
}

.flagTexture.flipImg {
    transform: scaleX(-1);
}

.flagTexture.defender {
    background-image: url('/img/flags/500px/teamSky.png') !important;
    box-shadow: inset 0 0 15px 3px black;
}

.flagTexture.attacker {
    background-image: url('/img/flags/500px/teamCrimson.png') !important;
    box-shadow: inset 0 0 15px 3px black;
}

.defenderInformations, .attackerInformations {
	align-items: center;
    bottom: 0;
    display: flex;
    flex-direction: row;
    justify-content: center;
    position: relative;
    width: 100%;
}
.defenderInformations i, .attackerInformations i {
	font-size: 1.5em;
}
.defenderInformations .icon-coins, .attackerInformations .icon-coins {
	padding-right: 0.2em;
}
.defenderInformations i::after, .attackerInformations i::after {
	font-size: 0.667em;
}

.battleSubsidies {
    border: 1px solid #000;
    border-radius: 3px;
    box-shadow: 3px 3px 3px #0008, 0 0 2px 2px #fff4 inset;
    display: none;
    font-size: 1.25em;
    line-height: 1.75em;
    padding: 0.25em 0.75em;
    position: absolute;
    text-align: left;
    text-shadow: 0 0 1px #000;
    top: 100%;
    width: max-content;
    z-index: 300;
}

.battleSubsidiesIcon:hover .battleSubsidies {
    display: block !important;
}

.battleSubsidies.defender {
    background: #041d28;
    left: 0;
}
.battleSubsidies.attacker {
    background: #3a0610;
    right: 0;
}
.battleSlimStatus .alliesList:hover .alliesPopup {
    display: block !important;
}

.battleFrozen {
    background-color: rgba(0, 0, 0, 0.61);
}

.battleFrozenText {
    top: 50%;
    position: absolute;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 3em;
    font-weight: bolder;
    background: black;
    border-radius: 0.5em;
    padding: 6px;
    width: 75%;
}

.battle__icons--swords {
    background-image: url('/img/buttonIcons/swords.png');
    background-repeat: no-repeat;
    background-position: center;
    background-size: 100% 100%;
    filter: invert(1) drop-shadow(0px 3px 2px black);
    width: 40px;
    height: 40px;
    min-width: 30px !important;
    margin: 0 auto;
}

.topSubsidedBattle {
    font-size: 1em;
    display: flex;
    justify-content: center;
    align-items: center;
}

.mobile .battle__icons--swords {
    width: 75px;
    height: 75px;
}

.topSubsidedBattle > .battleGrid, .topSubsidedBattle > .battleGrid > .battleParticipants,
.mobile .battleFooterTimer, .mobile .battleGrid > .battleParticipants {
    width: 100%;
}

.mobile .battleGrid > .battleParticipants, .mobile .battleFlagBackground {
    height: 250px;
}

.mobile .battleGrid .roundStatus .mainBar {
    height: 100px;
    text-shadow: 1px 1px 6px black, 1px 1px 6px black !important;
}

.mobile .roundStatus .mainBar .defendersPercent, .mobile .roundStatus .mainBar .attackersPercent,
.mobile .topSubsidedBattle .roundStatus .mainBar .defendersPercent, .mobile .topSubsidedBattle .roundStatus .mainBar .attackersPercent,
.mobile .topSubsidedBattle {
    font-size: 2em;
}

.mobile .battleOrderIcon {
    width: 65px;
    height: 65px;
}

.mobile .changingColor {
    font-size: 2.5em;
}

.mobile .battleGrid {
    width: 90%;
    font-size: 2em;
}

.mobile .battlesContainer {
    width: 100%;
}

.mobile .battleTotalDamage {
    font-size: 1.8em;
}

.mobile .battleFooter, .mobile .battleInformations {
    grid-template-columns: 1fr 350px 1fr;
}

/*old mobile Css for whole page refactored from jquery*/

.mobile #battlesViewForm {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    font-size: 5vw;
}

.mobile #battlesViewForm select {
    width: 50% !important;
    height: 90px;
    font-size: 3vw;
}

.mobile #battlesTable .button {
    font-size: 2.5vh !important;
    width: 40%;
}

.mobile button.btn-fight {
    border-radius: 15px;
    outline: 7px solid black;
    box-shadow: inset 0px -15px 2px 1px #054404, inset 0px 6px 9px 0px rgb(108 253 91) !important;
    padding: 0.85em 4.5em !important;
}

.mobile button.btn-fight:active {
    box-shadow: inset 0px 0px 3px 3px #054404, inset 0px 1px 4px 0px rgb(255 197 197) !important;
}

/*mateuszStyle*/

.mateuszStyle#battlesViewContainer .fightContainer, .mateuszStyle#battlesViewContainer .battlesHeader,
.mateuszStyle#battlesViewContainer .dropdownSelect {
    display: none;
}

.mateuszStyle#battlesViewContainer .battlesBg {
    background-image: url('https://cdn.discordapp.com/attachments/1008571248403562536/1131182083864285225/Railman_battlefield_empty_landscale_digital_painting_style_e4ab6d2f-f05b-4b71-88b3-aa6f045a6fb8.png') !important;
    background-position: center;
    background-size: cover !important;
    height: 300px;
    display: flex !important;
    align-items: center;
}

.mobile .mateuszStyle#battlesViewContainer .battlesBg.darkform .dropdownSelect {
    margin: 0.5em;
}

.mateuszStyle#battlesViewContainer .battlesBg > .battlesWrapper {
    background-color: #000000d4;
    width: 50%;
    margin: 0 auto 7.5em;
    border: 2px solid black;
    border-radius: 0.5em;
    box-shadow: 0 0 3px 1px black;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    zoom: 1.4;
}

.mateuszStyle#battlesViewContainer .battlesWrapper > h2 {
    font-size: 7vh !important;
}

#battlesTable > tbody > tr > td:nth-child(2) {
    font-size: 17px;
    font-weight: bold;
}
#battlesTable > tbody > tr > td:nth-child(3) {
    font-size: 11px;
    font-weight: bold;
}
#battlesTable > tbody > tr:first-child > td {
    font-size: 13px;
}
#battlesTable > tbody > tr > td > div > div.battleDiv > div:last-child {
    width: 220px !important;
}
    