/* /static/css/styles.css/ */
/* Alap beállítások */
body {
    background-color: #080709; 
    color: #cdcddb;
    font-family: 'Montserrat', sans-serif;
    margin: 0;
}
html, body {
    height: 100%;
    overflow: hidden;
    margin-bottom: 100px;
}

#menu-container.hidden {
    display: none !important;
}
#ws-container.hidden {
    display: block !important;
}

#ws-container {
    display: block !important;
}

.modalGlobal {
  position: fixed; /* vagy absolute, de fixed a legjobb modálnál */

  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(0, 0, 0, 0.5); /* átlátszó háttér */
  display: none; /* alapból rejtett */
  z-index: 10000; /* elég magas érték */
}

.modal-content {
  position: absolute;
  top: 5%; /* vagy 10%, ha jobban tetszik */
  left: 50%;
  transform: translateX(-50%);
  border: 2px solid #2b1f44;
  border-radius: 8px;
  padding: 20px;
  background-color: #1b1b1b;
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
  z-index: 10001;
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}
.close {
  color: #aaa;
  float: right;
  font-size: 24px;
  font-weight: bold;
  cursor: pointer;
}

/* Menü - mindig fix bal oldalon */
#menu-container {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 220px;
    height: 90vh;
    background-color: #080709;
    border-right: 2px solid #2b1f44;
    padding: 20px;
    margin-top: 20px;
    box-sizing: border-box;
    overflow-y: auto;
    z-index: 1000;
}

/* Tartalom terület - bal menü és alsó websocket box között */
#main-layout {
    margin-left: 220px;         /* hely a fix menünek */
    margin-bot: 0px;
    height: calc(100% - 55px);
    bottom: 0;
    overflow-y: auto;
    box-sizing: border-box;
}

/* Tartalom belül */
#content {
    box-sizing: border-box;
    height: 98%;
    margin: 20px;
}

/* WebSocket konténer - fix alul */
#resizer {
    height: 5px;
    width: 10%;
    cursor: ns-resize;
    position: absolute;

	border-top: 1px solid #a5a5a5;
	border-bottom: 1px solid #a5a5a5;
    top: 0;
    left: 45%;
    transform: translateX(-50%);
    z-index: 10;
}
#ws-container {
    position: fixed;
    padding: 10px;
    bottom: 0;
    left: 220px;
    background: #00000060;
    right: 0;
    height: 0px;
    min-height: 0px;
    box-sizing: border-box;
    padding-top: 10px; /* hogy ne takarja el a resizer */

}

#ws-messages {
    width: 100%;
    height: calc(100% - 5px); /* resizer magasságát kivonjuk */
    min-height: 5px;
    background: linear-gradient(to top, #080709 20%, #8c5eff25 80%);
    color: #cdcddb;
    font-size: 12px; /* fix szövegméret, nem skálázódik zoommal */
    border-top-width: 1px;
    border-top-style: none;
    padding: 10px;
    box-sizing: border-box;
    resize: none;
    font-family: monospace;
    white-space: pre-wrap;
    overflow-y: auto;
}

/* Menü stílus */
.menuheader {
    position: relative;
    text-align: center;
    padding: 10px;

}
.menuheader .title {
    display: flex;
    justify-content: center;
}
.menuheader .version {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 0.8em;
    color: #a5a5a5;
}
.menu ul {
    list-style-type: none;
    margin-top: 20px;
    padding: 0;
}

.menu li {
    margin-bottom: 5px;
    transition: background-color 0.3s;
}

.menu li:hover {
    background-color: #080709;
}

.menu a {
    color: #a5a5a5;
    text-decoration: none;
    text-align: center;
    display: block;
    padding: 2px;
    transition: color 0.3s;
}

.menu a:hover {
    color: #cdcddb;
}

/* Formázás */
form {
    display: flex;
    flex-direction: column;
}

input[type="text"],
input[type="number"],
input[type="email"],
input[type="password"],
textarea {
    background: linear-gradient(to top, #2b1f4485 1%, #1110 50%);   
    color: #cdcddb;
    border: none;
    border-bottom: 1px solid #a5a5a5;
    border-radius: 2px;
    outline: none;
    padding: 10px;
    width: 150px;
    box-sizing: border-box;
    margin-bottom: 15px;
}
input[type="text"],
input[type="number"],
input[type="email"],
input[type="password"],
textarea:focus {
    border-radius: 20px;
    border-bottom: 1px solid #a5a5a5;
}
label {
    color: #cdcddb;
    margin-bottom: 5px;
    display: block;
}

/* Gombok */
input[type="submit"],
button {
    background-color: #7e48fd;
    color: #fff;
    border: none;
    border-radius: 5px;
    padding: 10px 20px;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.2s;
    width: 300px;
    box-sizing: border-box;
    text-align: center;
}

input[type="submit"]:hover,
button:hover {
    background-color: #5a3f9e;
    transform: scale(1.05);
}

input[type="submit"]:active,
button:active {
    background-color: #4a3480;
    transform: scale(0.95);
}

input[type="submit"]:focus,
button:focus {
    outline: none;
    box-shadow: 0 0 5px #a5a5a5;
}

/* Flash üzenetek */
.flashes {
    background-color: #333333;
    color: #cdcddb;
    padding: 10px;
    border-radius: 5px;
    margin-bottom: 20px;
}

/* Címek és szövegek */
h0 {
    color: #a5a5a5;
    text-align: center;
    font-weight: bold;
    text-decoration: underline;
}

h1, h2, h3, h4, h5, h6 {
    color: #a5a5a5;
    margin: 10px 0;
}

p {
    margin: 10px 0;
    line-height: 1.6;
    text-align: left;
}
/* Container belül a content diven */
.settings-container {
  width: 100%;
  padding: 20px;
  box-sizing: border-box;
}

/* Tab navigation sáv vízszintesen felül, középen */
.settings-tabs {
  gap: 20px;
  white-space: unset;
  border-bottom: 2px solid #a5a5a5;
  padding-bottom: 10px;
  margin-bottom: 40px; /* Ez tolja le a contentet */
  width: 80%;
}

/* Tab gomb stílus */
.settings-tab {
  display: inline-block;
  background: none;
  white-space: nowrap;
  border: none;
  color: #cdcddb;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  padding: 20px 10px;
  border-bottom: 2px solid transparent;
  min-width: 100px;
  width: 200px;
  box-sizing: border-box;
  transition: border-color 0.3s, color 0.3s;
}

.settings-tab:hover {
  color: #a5a5a5a5a5a5;
  border-bottom: 2px solid #8c5eff;
}

.settings-tab.active {
  color: #a5a5a5a5a5a5;
  box-shadow: none;
  outline: none;
  border-bottom: 2px solid #a5a5a5;
  border-top: 0px;
}

/* A dinamikusan betöltött content helye */
#settings-content {
  width: 100%;
  margin-left: 20px;
  margin-right: 0 auto;
  box-sizing: border-box;
}
.table {
  width: 100%;
}
.hr {
  width: 77%;
  margin-left: 0px;
  justify-content: left;
}
.auth-container {
  height: 80vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin: 0 auto; /* vízszintes középre igazítás */
  text-align: center;
}
#loginbtn {
  display: block;
  width: 300px;
}

#login-form {
 margin-top: 50px;
}

.login-mode {

}
.username {
  padding-left: 20px !important;
  padding-right: 20px !important;
  display: block !important;
  width: 300px !important;
}
.howlerscode,
.password {
  padding-left: 20px !important;
  padding-right: 20px !important;
  display: block !important;
  width: 300px !important;
}

#logout-btn {
  display: block;
  background-color: #a32039c4;
  width: 100%;
}
.form-row {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.form-row label {
    width: 150px;
    margin-right: 10px;
    text-align: right;
}

.form-row input {
    flex: 1;
    padding: 10px;
    padding-left: 20px;
    padding-right: 20px;
    margin-right: 15px;
    width: 30%;
    border-radius: 0px;
    border-top: 0px;
    border-left: 0px;
    border-right: 0px;
    border-bottom: 2px solid white;
    padding-bottom: 9px;
}
.form-control {
  width: 20% !important;
}
#active-gridbots {
    margin-bottom: 20px;
}
#gridbot-wrapper {
    display: flex;
    flex-direction: row;
    gap: 40px;
}
#form-section-header {
    display: none;
    font-size: 20px;
    color: #a5a5a5;
    margin-bottom: 20px;
    margin-top: 10px;
    text-align: left;
}
#exchange-list {
    text-align: center;
}
.btn-danger,
.btn-secondary {
    background: transparent;
}
.btn-secondary:hover,
.btn-danger:hover {
    background: transparent;
    transition: transform 0.3s;
}
.btn-secondary:focus,
.btn-danger:focus {
    background: transparent;
    transition: transform 0.3s;
    box-shadow: none;
    outline: none;
    border: none;
}
.btn-secondary:active,
.btn-danger:active {
    background: transparent;
    transition: transform 0.3s;
    box-shadow: none;
    outline: none;
    border: none;
}
#calculation-panel {
    padding: 20px;
    color: #cdcddb;
}

#calculation-panel h3 {
    color: #8c5eff;
    margin-bottom: 15px;
    text-align: center;
}

#calculation-panel table {
    border-collapse: collapse;
}

#calculation-panel td {
    padding: 8px;
    border-bottom: 1px solid #444;
    font-family: monospace;
}

#calculation-panel td:first-child {
    font-weight: bold;
}


.gridbot-table {
    min-width: 95%;
    margin-left: 20px;
    margin-right: auto;
    box-sizing: border-box;
}
#total-inv {
  font-size: 1.5em;
}
#total-val {
  font-size: 1.2em;
}
#total-pnl {
  font-size: 1.2em;

}
.thead,
.active-bots {
    text-align: left;
}
#gform-btn,
#gform-btn:focus {
    background: transparent;
    color: #cdcddb;
    border: none;
    outline: none;
    box-shadow: none;
    padding-bottom:50px;
}

.active-bot-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 0px;
  padding: 1rem 1.5rem;
  margin-bottom: 1.5rem;
  color: #a5a5a5;
  box-shadow: 0 0 12px rgba(0,0,0,0.2);
  backdrop-filter: blur(6px);
}

.card-header {
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  margin-bottom: 1rem;
}

.price-bar {
  position: relative;
  height: 12px;
  background: linear-gradient(to left, #1d823b 40%, #821d30 50%);
  width: 150px;
  border-radius: 2px;
}
.price-marker{
  position: absolute;
  top: -2px;
  width: 8px;
  height: 16px;
  background: linear-gradient(to left, #821d30 50%, #1d823b 50%);
  left: 0%;
}
.card-subheader {
    display: flex;
    justify-content: space-between;
    font-variant: small-caps;
    color: #796f93;
    gap: 1rem;
}
.header-info {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    width: 100%;

}
.card-header h3 {
  margin: 0;
  font-variant: small-caps;
  font-size: 1.5rem;
  color: #a5a5a5a5a5a5;
}

.card-body p {
  margin: 0.4rem 0;
}

code {
    font-size: 1.4em;
    color: white;
    font-family: 'Courier New', Courier, monospace;
}
select {
  min-width: 225px !important;
  max-width: 225px !important;
  background-color: transparent !important;
  color: white !important;
  border-color: #a5a5a5;
  border-left: 0px;
  border-right: 0px;
  border-top: 0px;
  border-bottom: 1px solid #a5a5a5;
  padding-bottom: 9px;
  border-radius: 0px;
  font-size: 1em;
}

#home-div {
    margin-bottom: 50px;
    padding-bottom: 50px;
}
#patch-div {
    margin-bottom: 50px;
    padding-bottom: 50px;
}
#home-form,
#patch-form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem; /* egy kis hézag az elemek között */
}
#home-form textarea
#patch-form textarea {
    resize: vertical;
    min-height: 1px;
}

#home-title,
#home-content,
#patch-title,
#patch-content {
    margin-left: 5% !important;
    width: 90% !important;
    border-radius: 0px !important;
    margin-bottom: 0px !important;
}

#submit-home,
#submit-patch {
    background: transparent !important;
    outline: none;
    box-shadow: 0 0 0px transparent;
    margin-left: auto;
    padding-top: 10px;
    padding-bottom: 30px;
}

.card-body {
    border: 1px solid #483777;
    background: linear-gradient(0deg, #a5a5a52e, #a5a5a50);
    padding: 20px;
    margin-left: 30px;
    margin-right: 30px;
}
.card-body-container {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    gap: 1rem;
}
.card-body-left,
.card-body-right {
    flex: 1;
}
.card-body-right table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.card-body-right th,
.card-body-right td {
    padding: 0.5rem 0.75rem;
    border: 1px solid #483777;
    text-align: left;
}

.card-body-right th {
    background-color: #483777;
    font-weight: bold;
}

.card-body-right tr:nth-child(even) {
    background-color: #201f22;
}
.card-title {
    color: #a5a5a5;
    margin: 10px 0;
    font-size: 1.6em;
    border-bottom: 3px solid #483777;
}
.card-text {
    padding: 20px;
}
.card-footer {
    border: 1px solid #483777;
    border-top: none;
    background-color: #5f42b25c;
    margin-left: 30px;
    margin-right: 30px;
    padding: 5px;
    padding-left: 40px;
}
.card {
    margin-bottom: 5px;
}

.card-id-hidden {
    display: none !important;
}
.card-body.collapsed {
    display: none;
}

#menu_logo {
  width: 155px;
}

#login-logo,
#reg-logo {
  width: 220px;
  padding-bottom: 20px;
}
