* {
  box-sizing: border-box;
}

html, body {
  width: 100%;
  min-height: 100%;
  margin: 0;
}

body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  font-family: "Imprima", sans-serif;
  font-weight: 500;
  font-style: normal;
  color: #555;
  /* overflow: hidden; */

  /* Soft gradient inspired by the supplied reference image */
  background:
    radial-gradient(circle at 12% 18%, rgba(246, 214, 166, .55), transparent 34%),
    radial-gradient(circle at 88% 82%, rgba(255, 225, 216, .60), transparent 32%),
    radial-gradient(circle at 72% 20%, rgba(192, 124, 63, .48), transparent 38%),
    radial-gradient(circle at 32% 90%, rgba(112, 38, 102, .72), transparent 42%),
    linear-gradient(135deg, #d7b17d 0%, #bd7a3e 45%, #9c245c 100%);
}

.login-card {
  width: min(100%, 430px);
  padding: 18px 0 12px;
  text-align: center;
}

.user-icon {
  width: 96px;
  height: 96px;
  margin: 0 auto 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 246, 227, .78);
  box-shadow: 0 4px 18px rgba(70, 25, 30, .08);
}

.user-icon svg {
  width: 60px;
  height: 60px;
  fill: none;
  stroke: #bd9a78;
  stroke-width: 2;
}

.field {
  width: 100%;
  height: 43px;
  display: flex;
  margin-bottom: 11px;
  background: rgba(255, 249, 239, .82);
  box-shadow: 0 2px 7px rgba(70, 25, 30, .05);
}

.field-icon {
  width: 44px;
  flex: 0 0 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, .65);
  color: #555;
}

.field-icon svg {
  width: 17px;
  height: 17px;
  fill: currentColor;
}

.field input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  padding: 0 14px;
  background: transparent;
  color: #555;
  font-size: 14px;
  letter-spacing: .2px;
}

.field input::placeholder {
  color: #9a918b;
  opacity: 1;
}

.options {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin: 4px 10px 20px;
  font-size: 12px;
}

.remember {
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  cursor: pointer;
}

.remember input {
  appearance: none;
  width: 14px;
  height: 14px;
  margin: 0;
  border-radius: 1px;
  background: rgba(255, 255, 255, .72);
  box-shadow: inset 0 0 0 1px rgba(90, 70, 70, .15);
  cursor: pointer;
  position: relative;
}

.remember input:checked::after {
  content: "?";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: 11px;
  color: #fff;
  background: rgba(70, 65, 65, .8);
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.login-button {
  width: 100%;
  height: 52px;
  border: 0;
  cursor: pointer;
  color: #fff;
  background: rgba(221, 168, 164, .94);
  box-shadow: 0 7px 14px rgba(90, 25, 40, .25);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 2px;
  transition: transform .15s ease, background .15s ease, box-shadow .15s ease;
}

.login-button:hover {
  background: rgba(210, 151, 149, .98);
  transform: translateY(-1px);
  box-shadow: 0 9px 17px rgba(90, 25, 40, .28);
}

.login-button:active {
  transform: translateY(0);
}

.register {
  margin-top: 22px;
  font-size: 13px;
  color: rgba(255, 248, 240, .88);
}

.register a {
  font-weight: 600;
  color: #fff;
}
.login_info {
	border: 1px solid rgba(200, 148, 210, .68);
	color: rgba(255, 248, 240, .88);
	font-size: 85%;
	padding: 5px;
	margin-bottom: 10px;
}

@media (max-width: 480px) {
  body {
    padding: 20px;
  }

  .login-card {
    width: min(100%, 360px);
  }

  .user-icon {
    width: 82px;
    height: 82px;
    margin-bottom: 23px;
  }

  .user-icon svg {
    width: 52px;
    height: 52px;
  }

  .options {
    margin-left: 4px;
    margin-right: 4px;
  }
}

@media (max-height: 620px) {
  .user-icon {
    width: 70px;
    height: 70px;
    margin-bottom: 16px;
  }

  .user-icon svg {
    width: 46px;
    height: 46px;
  }

  .field {
    height: 40px;
    margin-bottom: 8px;
  }

  .options {
    margin-bottom: 14px;
  }

  .login-button {
    height: 47px;
  }
}

.footer {
    position: static;
    width: 100%;
    margin-top: 20px;
    padding-bottom: 20px;
    text-align: center;
    font-size: 15px;
    color: rgba(255, 255, 255, 0.75);
}

.footer a{
  color: rgba(200, 148, 210, .68);
}

.footer b{
  font-weight: bold;
  color: rgba(200, 148, 210, .68);
}

/* =========================
   PORTAL
   ========================= */

.portal_menu {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    padding: 14px 20px;
    margin-bottom: 28px;

    background: rgba(255,255,255,0.92);
    border-radius: 14px;

    box-shadow: 0 8px 30px rgba(0,0,0,0.08);
}

.portal_menu a {
    text-decoration: none;
    /* color: #555; */
	color: rgb(219, 20, 60, 0.5);
	font-size: 14px;
    font-weight: 500;

    padding: 9px 16px;
    border-radius: 8px;

    transition: all 0.2s ease;
}

.portal_menu a b{
	border-bottom: 1px solid rgb(219, 20, 60, 0.3);
}

.portal_menu a:hover {
    background: #f3f3f3;
    color: #222;
}

.portal_menu a.active {
    background: #7b2430;
    color: white;
}

.mobile_menu_button {
    display: none;
}

.portal_menu_links {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 28px;
}

/* MOBILE */

@media (max-width: 700px) {

    .portal_menu {
        position: relative;
        padding: 12px 16px;
        min-height: 46px;
        box-sizing: border-box;
    }

    .mobile_menu_button {
        display: block;
        margin-left: auto;

        border: 0;
        background: transparent;
        color: inherit;

        font-size: 26px;
        cursor: pointer;
    }

    .portal_menu_links {
        display: none;

        flex-direction: column;
        align-items: stretch;

        gap: 0;

        padding-top: 10px;
    }

    .portal_menu.open .portal_menu_links {
        display: flex;
    }

    .portal_menu_links a {
        display: block;
        padding: 12px 8px;
        text-align: center;
    }
}

/* =========================
   CONTENT
   ========================= */

.portal_content {
    width: min(1500px, 100%);
    margin: 0 auto;
	/* flex: 1; */
}


/* Header */

.portal_header {
    display: flex;
    align-items: center;
    justify-content: space-between;

    margin-bottom: 20px;
}

.portal_header h1 {
    margin: 0;
    font-size: 26px;
    font-weight: 600;
    color: #333;
}

.portal_header p {
    margin: 5px 0 0;
    color: #777;
    font-size: 14px;
}


/* Period selector */

.portal_period {
    display: flex;
    gap: 4px;

    padding: 4px;
    background: rgba(255,255,255,0.75);
    border-radius: 9px;
}

.portal_period button {
    border: 0;
    background: transparent;

    padding: 7px 12px;
    border-radius: 6px;

    font-size: 13px;
    color: #666;

    cursor: pointer;
}

.portal_period button:hover {
    background: #eee;
}

.portal_period button.active {
    background: #7b2430;
    color: white;
}


/* =========================
   CARDS
   ========================= */

.portal_card {
    background: rgba(255,255,255,0.94);
    border-radius: 14px;

    box-shadow: 0 8px 30px rgba(0,0,0,0.07);

    padding: 22px;
}


/* =========================
   MAIN CHART
   ========================= */

.chart_card {
    margin-bottom: 20px;
}

.card_header {
    display: flex;
    justify-content: space-between;
    align-items: center;

    margin-bottom: 10px;
}

.card_header h2 {
    margin: 0;
    font-size: 17px;
    font-weight: 600;
    color: #333;
}

.card_header span {
    display: block;
    margin-top: 4px;

    font-size: 12px;
    color: #888;
}

.card_value {
    font-size: 22px;
    font-weight: 600;
    color: #7b2430;
}

#power_chart {
    width: 100%;
    height: 350px;
}


/* =========================
   STATISTICS
   ========================= */

.stats_grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;

    margin-bottom: 20px;
}

.stat_card {
    padding: 20px;
}

.stat_label {
    display: block;

    font-size: 12px;
    color: #888;
    margin-bottom: 8px;
}

.stat_card strong {
    display: block;

    font-size: 24px;
    font-weight: 600;
    color: #333;
}

.stat_card small {
    display: block;

    margin-top: 5px;
    font-size: 12px;
    color: #999;
}


/* =========================
   INFORMATION CARDS
   ========================= */

.info_grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.info_card {
	overflow-x: auto;
}

.info_card h2 {
    margin: 0 0 16px;

    font-size: 16px;
    font-weight: 600;
    color: #333;
}

.status_row {
    display: flex;
    align-items: center;
    justify-content: space-between;

    padding: 10px 0;

    border-bottom: 1px solid #eee;

    font-size: 13px;
    color: #666;
}

.status_row:last-child {
    border-bottom: 0;
}

.status_row strong {
    color: #444;
    font-weight: 500;
}

.status_ok {
    color: #3b8060 !important;
}


/* =========================
   RESPONSIVE
   ========================= */

@media (max-width: 800px) {

    .stats_grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .info_grid {
        grid-template-columns: 1fr;
    }

    .portal_header {
        align-items: flex-start;
        flex-direction: column;
        gap: 15px;
    }

}

@media (max-width: 500px) {

    .portal_menu {
        justify-content: flex-start;
        overflow-x: auto;
    }

    .portal_menu a {
        white-space: nowrap;
    }

    .stats_grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }

    .portal_card {
        padding: 16px;
    }

    .stat_card strong {
        font-size: 20px;
    }

    #power_chart {
        height: 280px;
    }

}

td.editable {
    cursor: pointer;
}

td.editable:hover {
    background: rgba(0, 0, 0, 0.03);
}

td.editable input {
    width: 100%;
    box-sizing: border-box;

    border: 1px solid #aaa;
    border-radius: 5px;

    padding: 5px 7px;

    font: inherit;
    color: inherit;
    background: white;
}

.dev_tbl{
	min-width: 600px;
}
.dev_tbl td{
	border-bottom: 1px solid #AAA;
	padding: 2px;
	font-size: 85%;
	text-align: center;
}
.dev_tbl tr{
	font-size: 110%;
}
.btn_del{
	font-weight: bold;
	font-size: 85%;
	color: rgb(219, 20, 60, 0.5);
}