/*
 * Panel de usuario · mismo cielo, oro y tarjetas que la web pública.
 * No cambia menús, rutas ni campos.
 */

html,
body.icp-refined {
  min-height: 100%;
  background-color: #070506 !important;
}

body.icp-refined {
  color: #efe8dc !important;
  min-height: 100vh;
  background-image: none !important;
  background-color: #070506 !important;
}

body.icp-refined .icp-sky {
  position: fixed;
  z-index: 0;
  top: -6%;
  left: -12%;
  width: 124%;
  height: calc(100% + 120px);
  max-width: none;
  object-fit: cover;
  object-position: center 22%;
  pointer-events: none;
}

body.icp-refined .icp-dust {
  position: fixed;
  z-index: 1;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

body.icp-refined > header,
body.icp-refined > .container-fluid,
body.icp-refined > .form-signin,
body.icp-refined > main {
  position: relative;
  z-index: 2;
}

body.icp-refined main.form-signin,
body.icp-refined .form-signin {
  width: min(440px, calc(100% - 32px)) !important;
  max-width: 440px !important;
  margin: 22vh auto 48px !important;
  padding: 28px 26px 22px !important;
  border: 1px solid rgba(228, 192, 138, .72) !important;
  border-radius: 0 !important;
  background:
    linear-gradient(180deg, rgba(228, 192, 138, .1), transparent 42%),
    rgba(7, 5, 6, .78) !important;
  box-shadow:
    inset 0 0 0 4px rgba(7, 5, 6, .92),
    inset 0 0 0 5px rgba(228, 192, 138, .38) !important;
}

body.icp-refined .form-signin::before {
  width: 42px !important;
  height: 42px !important;
  margin-bottom: 12px !important;
  border-radius: 0 !important;
  font-size: 22px !important;
}

body.icp-refined .form-signin h1,
body.icp-refined .form-signin .h3 {
  margin-bottom: 16px !important;
  font-size: 26px !important;
  letter-spacing: .04em;
}

body.icp-refined .form-signin .form-control {
  border: 1px solid rgba(228, 192, 138, .4) !important;
  border-radius: 0 !important;
  background: rgba(0, 0, 0, .45) !important;
  color: #f6efe4 !important;
}

body.icp-refined .form-signin .btn-primary {
  min-height: 44px;
  margin-top: 8px;
}

@media (max-height: 760px) {
  body.icp-refined main.form-signin,
  body.icp-refined .form-signin {
    margin-top: 8vh !important;
  }
}

body.icp-refined header.navbar,
body.icp-refined header.navbar.navbar-dark.sticky-top.bg-white.flex-md-nowrap.p-0.shadow {
  background: rgba(8, 5, 6, .94) !important;
  border-bottom: 1px solid rgba(154, 48, 64, .5) !important;
  box-shadow: none !important;
}

body.icp-refined header.navbar .navbar-brand,
body.icp-refined header.navbar.navbar-dark.sticky-top.bg-white.flex-md-nowrap.p-0.shadow .navbar-brand {
  color: #f4ead4 !important;
  font-family: "Cinzel", Georgia, serif !important;
}

body.icp-refined .panel-brand-mark {
  border: 1px solid rgba(228, 196, 122, .75) !important;
  background: transparent !important;
  color: #f0d48a !important;
}

body.icp-refined header.navbar .dropdown-toggle,
body.icp-refined header.navbar .navbar-nav .nav-link {
  border: 1px solid rgba(154, 48, 64, .55) !important;
  border-radius: 999px !important;
  background: rgba(18, 8, 10, .8) !important;
  color: #f6e7c4 !important;
}

body.icp-refined #sidebarMenu,
body.icp-refined #sidebarMenu.col-md-3.col-lg-2 {
  background:
    linear-gradient(180deg, rgba(120, 28, 42, .18), transparent 8rem),
    rgba(8, 5, 6, .96) !important;
  border-right: 1px solid rgba(154, 48, 64, .4) !important;
}

body.icp-refined #sidebarMenu .menu-title > .nav-link,
body.icp-refined #sidebarMenu .menu-title > .nav-link strong {
  color: #e8d7a6 !important;
  font-family: "Cinzel", Georgia, serif !important;
  letter-spacing: .12em;
  text-transform: uppercase;
}

body.icp-refined #sidebarMenu .nav-item:not(.menu-title) > .nav-link,
body.icp-refined #sidebarMenu .nav-link {
  border-radius: 10px !important;
  color: #ddd4c6 !important;
}

body.icp-refined #sidebarMenu .nav-link:hover,
body.icp-refined #sidebarMenu .nav-link.active,
body.icp-refined #sidebarMenu .nav-link[aria-current="page"] {
  background: rgba(154, 48, 64, .2) !important;
  color: #fff1ea !important;
}

body.icp-refined main .card,
body.icp-refined main .dashboard-card,
body.icp-refined .panel-content-shell .card {
  border: 1px solid rgba(154, 48, 64, .4) !important;
  border-radius: 16px !important;
  background: rgba(12, 8, 9, .9) !important;
  box-shadow: 0 16px 36px rgba(0, 0, 0, .24) !important;
}

body.icp-refined .card-header,
body.icp-refined .panel-heading-block,
body.icp-refined h1,
body.icp-refined h2,
body.icp-refined h3 {
  color: #e8d7a6 !important;
  font-family: "Cinzel", Georgia, serif;
}

body.icp-refined .btn-primary,
body.icp-refined .btn-success,
body.icp-refined button.btn-primary {
  border: 0 !important;
  border-radius: 8px !important;
  background: linear-gradient(180deg, #f0d48a, #c4963e) !important;
  color: #1a140c !important;
}

body.icp-refined .form-control,
body.icp-refined .custom-select,
body.icp-refined select.form-control {
  border: 1px solid rgba(154, 48, 64, .4) !important;
  border-radius: 8px !important;
  background: rgba(8, 5, 6, .9) !important;
  color: #f4ecdf !important;
}

body.icp-refined .table {
  color: #efe8dc;
}

body.icp-refined .table thead th {
  border-color: rgba(214, 176, 96, .28) !important;
  color: #e8d7a6 !important;
  font-family: "Cinzel", Georgia, serif;
}

/* Mi cuenta: franja de resumen y, justo debajo, los personajes. */
body.icp-refined main,
body.icp-refined main.col-md-9.ms-sm-auto.col-lg-10 {
  flex: 1 1 auto !important;
  width: auto !important;
  max-width: none !important;
}

body.icp-refined .account-page {
  display: flex !important;
  flex-direction: column !important;
  align-items: stretch !important;
  align-content: flex-start !important;
  justify-content: flex-start !important;
  width: 100% !important;
  height: auto !important;
  min-height: 0 !important;
  max-width: none !important;
  gap: 10px;
}

body.icp-refined .account-page > .account-summary {
  display: grid !important;
  grid-template-columns: minmax(220px, 1fr) minmax(260px, 1.15fr) minmax(220px, .9fr);
  grid-template-rows: auto 148px 48px;
  gap: 8px 14px;
  align-content: start !important;
  align-items: start !important;
  width: 100% !important;
  height: auto !important;
  min-height: 0 !important;
  max-width: none !important;
  flex: 0 0 auto !important;
}

body.icp-refined .account-page > .account-summary > .account-section-heading {
  grid-column: 1 / -1;
  grid-row: 1;
  min-height: 0 !important;
  margin: 0 !important;
  padding: 2px 0 6px !important;
}

/* nth-child, no nth-of-type: el título también es un div y desplazaba las tarjetas. */
body.icp-refined .account-page > .account-summary > .card:nth-child(2) {
  grid-column: 1;
  grid-row: 2;
}

body.icp-refined .account-page > .account-summary > .row {
  grid-column: 1;
  grid-row: 3;
  margin: 0 !important;
}

body.icp-refined .account-page > .account-summary > #withdraw-coins,
body.icp-refined .account-page > .account-summary > .card:nth-child(5) {
  grid-row: 2 / span 2;
  align-self: stretch;
  display: flex !important;
  flex-direction: column;
  height: 100% !important;
  min-height: 0;
  max-height: 100%;
  overflow: hidden;
}

body.icp-refined .account-page > .account-summary > #withdraw-coins > .card-body,
body.icp-refined .account-page > .account-summary > .card:nth-child(5) > .card-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
}

body.icp-refined #withdraw-coins > .card-body {
  display: flex;
  flex-direction: column;
}

body.icp-refined #withdraw-coins > .card-body > form {
  order: -1;
  margin-top: 0 !important;
}

body.icp-refined .account-page > .account-summary > #withdraw-coins {
  grid-column: 2;
}

body.icp-refined .account-page > .account-summary > .card:nth-child(5) {
  grid-column: 3;
}

body.icp-refined .account-summary > .card,
body.icp-refined .account-summary .card {
  margin-bottom: 0 !important;
}

body.icp-refined .account-summary .card-header {
  min-height: 0 !important;
  padding: 8px 12px !important;
}

body.icp-refined .account-summary .card-body {
  padding: 10px 12px !important;
}

body.icp-refined .account-summary .btn,
body.icp-refined .account-summary button.modal-btn.btn-primary {
  min-height: 36px;
  margin-bottom: 0 !important;
}

body.icp-refined #withdraw-coins p,
body.icp-refined #withdraw-coins h6,
body.icp-refined #withdraw-coins hr,
body.icp-refined #withdraw-coins .mb-2,
body.icp-refined #withdraw-coins .mb-3,
body.icp-refined #withdraw-coins .mt-3,
body.icp-refined #withdraw-coins .small {
  margin-top: 6px !important;
  margin-bottom: 6px !important;
}

body.icp-refined #withdraw-coins .card-body > div[style*="margin-top"] {
  margin-top: 8px !important;
}

body.icp-refined #withdraw-coins form .btn {
  position: sticky;
  bottom: 0;
  z-index: 2;
}

body.icp-refined .account-summary .ip-history-card-body {
  padding: 8px 10px !important;
}

body.icp-refined .account-summary .ip-history-card-body h5 {
  margin: 0 0 6px !important;
  padding: 0 0 6px !important;
}

body.icp-refined .account-summary .ip-history-table tbody {
  gap: 4px !important;
}

body.icp-refined .account-page > .account-characters {
  width: 100% !important;
  height: auto !important;
  min-height: 0 !important;
  max-width: none !important;
  flex: 0 0 auto !important;
  align-self: start !important;
  margin-top: 0 !important;
  padding-top: 0 !important;
  padding-left: 0 !important;
}

body.icp-refined .account-characters > .account-section-heading {
  min-height: 0 !important;
  margin-bottom: 10px !important;
  padding-top: 0 !important;
  padding-bottom: 8px !important;
}

body.icp-refined .account-characters > .row {
  display: flex !important;
  flex-wrap: wrap;
}

body.icp-refined .character-card-column {
  flex: 1 1 calc(50% - 16px) !important;
  width: auto !important;
  max-width: none !important;
  min-width: min(100%, 280px);
}

body.icp-refined main .card,
body.icp-refined .account-page .card {
  border: 1px solid rgba(228, 192, 138, .72) !important;
  border-radius: 0 !important;
  background:
    linear-gradient(180deg, rgba(228, 192, 138, .1), transparent 42%),
    rgba(0, 0, 0, .55) !important;
  box-shadow:
    inset 0 0 0 4px rgba(7, 5, 6, .92),
    inset 0 0 0 5px rgba(228, 192, 138, .38) !important;
}

body.icp-refined .card-header {
  border-bottom: 1px solid rgba(228, 192, 138, .28) !important;
  background: transparent !important;
  color: #e4c08a !important;
  font-family: "Cinzel", Georgia, serif !important;
  letter-spacing: .06em;
}

body.icp-refined .btn-primary,
body.icp-refined .btn-secondary,
body.icp-refined a.btn {
  border: 1px solid rgba(228, 192, 138, .72) !important;
  border-radius: 0 !important;
  background:
    linear-gradient(180deg, rgba(228, 192, 138, .12), transparent 46%),
    rgba(0, 0, 0, .55) !important;
  box-shadow:
    inset 0 0 0 3px rgba(7, 5, 6, .92),
    inset 0 0 0 4px rgba(228, 192, 138, .32) !important;
  color: #f3eadf !important;
  font-family: "Cinzel", Georgia, serif;
}

body.icp-refined .btn,
body.icp-refined .btn-primary,
body.icp-refined .btn-secondary,
body.icp-refined .btn-success,
body.icp-refined .btn-danger,
body.icp-refined .btn-warning,
body.icp-refined .btn-info,
body.icp-refined .btn-light,
body.icp-refined .btn-dark,
body.icp-refined .btn-outline-primary,
body.icp-refined .btn-outline-secondary,
body.icp-refined .btn-outline-success,
body.icp-refined .btn-outline-danger,
body.icp-refined .btn-outline-warning,
body.icp-refined .btn-outline-info,
body.icp-refined .btn-outline-light,
body.icp-refined .btn-outline-dark,
body.icp-refined a.btn,
body.icp-refined input[type="submit"],
body.icp-refined button[type="submit"],
body.icp-refined .form-signin .btn-primary {
  color: #2a1a0c !important;
  border: 1px solid #6e4c28 !important;
  border-radius: 2px !important;
  background:
    linear-gradient(180deg, rgba(255, 236, 206, .55), transparent 46%),
    linear-gradient(180deg, #e4c08a 0%, #a56b38 46%, #6d4522 78%, #c4925a 100%) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 236, 206, .8),
    inset 0 -2px 0 rgba(48, 28, 12, .55) !important;
  font-family: "Cinzel", Georgia, serif;
  letter-spacing: .06em;
  text-shadow: none;
}

body.icp-refined table,
body.icp-refined .table {
  border: 1px solid rgba(228, 192, 138, .72) !important;
  border-collapse: separate !important;
  border-spacing: 0 !important;
  border-radius: 0 !important;
  background: rgba(7, 5, 6, .55) !important;
  box-shadow:
    inset 0 0 0 4px rgba(7, 5, 6, .92),
    inset 0 0 0 5px rgba(228, 192, 138, .38) !important;
  color: #efe8dc !important;
}

body.icp-refined .table th,
body.icp-refined .table td,
body.icp-refined table th,
body.icp-refined table td {
  border-color: rgba(228, 192, 138, .22) !important;
  background-color: transparent !important;
  color: #efe8dc !important;
}

body.icp-refined .table thead th,
body.icp-refined table thead th {
  color: #e4c08a !important;
  font-family: "Cinzel", Georgia, serif !important;
}

body.icp-refined .account-page button.modal-btn.btn-primary {
  color: #2a1a0c !important;
  border: 1px solid #6e4c28 !important;
  border-radius: 2px !important;
  background:
    linear-gradient(180deg, rgba(255, 236, 206, .55), transparent 46%),
    linear-gradient(180deg, #e4c08a 0%, #a56b38 46%, #6d4522 78%, #c4925a 100%) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 236, 206, .8),
    inset 0 -2px 0 rgba(48, 28, 12, .55) !important;
  font-family: "Cinzel", Georgia, serif !important;
  font-size: 13px !important;
  letter-spacing: .04em;
  min-height: 44px;
}

@media (max-width: 820px) {
  body.icp-refined .account-page > .account-summary {
    grid-template-columns: 1fr;
    grid-template-rows: none;
  }

  body.icp-refined .account-page > .account-summary > #withdraw-coins,
  body.icp-refined .account-page > .account-summary > .card:nth-child(5) {
    height: auto !important;
    max-height: none;
    overflow: visible;
  }

  body.icp-refined .account-page > .account-summary > #withdraw-coins > .card-body,
  body.icp-refined .account-page > .account-summary > .card:nth-child(5) > .card-body {
    overflow: visible;
  }

  body.icp-refined .account-page > .account-summary > .account-section-heading,
  body.icp-refined .account-page > .account-summary > .card:nth-child(2),
  body.icp-refined .account-page > .account-summary > .row,
  body.icp-refined .account-page > .account-summary > #withdraw-coins,
  body.icp-refined .account-page > .account-summary > .card:nth-child(5) {
    grid-column: auto;
    grid-row: auto;
  }

  body.icp-refined .character-card-column {
    flex-basis: 100% !important;
    width: 100% !important;
    max-width: 100% !important;
  }
}

/* Personajes al lado del resumen, desde arriba, como en el panel antiguo. */
body.icp-refined .account-page {
  flex-direction: row !important;
  flex-wrap: nowrap !important;
  align-items: flex-start !important;
  gap: 22px !important;
}

body.icp-refined .account-page > .account-summary {
  display: flex !important;
  flex: 0 0 300px !important;
  flex-direction: column !important;
  width: 300px !important;
  min-width: 300px !important;
  max-width: 300px !important;
}

body.icp-refined .account-page > .account-summary > .account-section-heading,
body.icp-refined .account-page > .account-summary > .card,
body.icp-refined .account-page > .account-summary > .row,
body.icp-refined .account-page > .account-summary > #withdraw-coins {
  grid-column: auto !important;
  grid-row: auto !important;
  width: 100% !important;
  height: auto !important;
  max-height: none !important;
  overflow: visible !important;
}

body.icp-refined .account-page > .account-characters {
  flex: 1 1 auto !important;
  width: auto !important;
  min-width: 0 !important;
  margin-top: 0 !important;
}

@media (max-width: 980px) {
  body.icp-refined .account-page {
    flex-direction: column !important;
  }

  body.icp-refined .account-page > .account-summary {
    flex: none !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: none !important;
  }
}
