:root {
  --morado: #32005a;
  --magenta: #ff2b50;
  --blanco: #ffffff;
  --bg: #04030a;
  --panel: #091120;
  --panel-2: #0d1830;
  --text: #ffffff;
  --muted: #a9b0c4;
  --line: rgba(255, 255, 255, 0.08);
  --success: #22c55e;
  --warning: #f59e0b;
  --blue: #2d89ff;
  --purple: #7b1fff;
  --shadow: 0 18px 45px rgba(0, 0, 0, 0.28);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  font-family:
    "DM Sans",
    Inter,
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  background:
    radial-gradient(
      circle at 20% 0%,
      rgba(123, 31, 255, 0.18),
      transparent 34%
    ),
    radial-gradient(
      circle at 80% 10%,
      rgba(255, 43, 80, 0.12),
      transparent 28%
    ),
    linear-gradient(135deg, #02040b 0%, #050816 48%, #04010a 100%);
  color: var(--text);
  min-height: 100vh;
}

button,
input {
  font: inherit;
}
button {
  cursor: pointer;
}
a {
  color: inherit;
  text-decoration: none;
}

.app {
  display: grid;
  grid-template-columns: 292px 1fr;
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: auto;
  background: linear-gradient(180deg, #070c18 0%, #050713 45%, #0a0015 100%);
  color: var(--blanco);
  padding: 22px 18px;
  box-shadow: 22px 0 55px rgba(50, 0, 90, 0.18);
  z-index: 20;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
}
.brand-mark {
  width: 54px;
  height: 54px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--magenta), #7b1fff);
  box-shadow: 0 14px 35px rgba(255, 43, 80, 0.35);
  font-weight: 1000;
  font-size: 28px;
  letter-spacing: -2px;
}
.brand h1 {
  font-size: 24px;
  margin: 0;
  line-height: 1;
  font-weight: 1000;
  letter-spacing: 0.2px;
}
.brand small {
  display: block;
  margin-top: 6px;
  color: #ffb6c5;
  font-size: 10px;
  letter-spacing: 1.7px;
  font-weight: 800;
}

.nav-section {
  margin: 22px 0 10px;
  color: rgba(255, 255, 255, 0.55);
  font-size: 11px;
  letter-spacing: 0.9px;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 10px;
}
.nav-section:after {
  content: "";
  height: 1px;
  background: rgba(255, 255, 255, 0.15);
  flex: 1;
}

.nav-item {
  width: 100%;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.84);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 13px;
  border-radius: 16px;
  margin: 3px 0;
  transition: 0.22s ease;
  text-align: left;
}
.nav-item span {
  display: flex;
  align-items: center;
  gap: 11px;
  font-weight: 700;
  font-size: 14px;
}
.nav-item:hover,
.nav-item.active {
  background: linear-gradient(135deg, #7b1fff, var(--magenta));
  color: #fff;
  box-shadow: 0 12px 28px rgba(255, 43, 80, 0.2);
}

.help-card {
  margin-top: 28px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: linear-gradient(
    135deg,
    rgba(255, 43, 80, 0.3),
    rgba(123, 31, 255, 0.28)
  );
  padding: 18px;
  border-radius: 22px;
}
.help-card h3 {
  margin: 0 0 8px;
  font-size: 16px;
}
.help-card p {
  margin: 0;
  color: rgba(255, 255, 255, 0.76);
  font-size: 13px;
  line-height: 1.45;
}
.help-card button {
  margin-top: 14px;
  border: 0;
  border-radius: 13px;
  background: var(--magenta);
  color: #fff;
  font-weight: 900;
  padding: 10px 14px;
  box-shadow: 0 12px 22px rgba(255, 43, 80, 0.25);
}
.copyright {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.55);
  margin: 22px 8px 0;
  line-height: 1.6;
}

.main {
  padding: 20px;
  overflow: hidden;
}
.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  margin-bottom: 18px;
}
.menu-btn {
  display: none;
  border: 0;
  background: var(--panel);
  border-radius: 14px;
  padding: 12px;
  box-shadow: var(--shadow);
}
.search {
  position: relative;
  flex: 1;
  max-width: 760px;
}
.search input {
  width: 100%;
  border: 1px solid var(--line);
  background: rgba(7, 13, 24, 0.95);
  border-radius: 18px;
  padding: 15px 48px;
  outline: none;
  box-shadow: 0 12px 28px rgba(50, 0, 90, 0.06);
}
.search input:focus {
  border-color: rgba(255, 43, 80, 0.55);
  box-shadow: 0 0 0 4px rgba(255, 43, 80, 0.1);
}
.search .icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--morado);
}
.shortcut {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 12px;
  color: var(--muted);
  border: 1px solid var(--line);
  padding: 4px 8px;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.08);
}
.user-area {
  display: flex;
  align-items: center;
  gap: 12px;
}
.bell {
  position: relative;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 16px;
  width: 46px;
  height: 46px;
  font-size: 18px;
  box-shadow: var(--shadow);
}
.bell b {
  position: absolute;
  right: -3px;
  top: -5px;
  background: var(--magenta);
  color: #fff;
  border-radius: 999px;
  font-size: 10px;
  padding: 3px 6px;
}
.profile {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(9, 17, 32, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  padding: 8px 12px;
  box-shadow: var(--shadow);
}
.avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--morado), var(--magenta));
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 900;
}
.profile strong {
  display: block;
  font-size: 14px;
}
.profile small {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 18px;
}
.hero {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  background: linear-gradient(105deg, #060a16 0%, #0a1120 46%, #140028 100%);
  border-radius: var(--radius);
  padding: 28px 32px;
  box-shadow: var(--shadow);
  min-height: 210px;
}
.hero:after {
  content: "";
  position: absolute;
  right: -40px;
  top: 0;
  width: 55%;
  height: 100%;
  background:
    radial-gradient(
      circle at 45% 45%,
      rgba(255, 43, 80, 0.42),
      transparent 22%
    ),
    linear-gradient(105deg, transparent, rgba(50, 0, 90, 0.18));
  clip-path: polygon(8% 0, 100% 0, 100% 100%, 24% 100%);
  opacity: 0.8;
}
.fiber {
  position: absolute;
  right: 20px;
  top: 52px;
  width: 360px;
  height: 120px;
  z-index: 0;
  opacity: 0.95;
}
.hero-d {
  position: absolute;
  right: -30px;
  top: 50%;
  transform: translateY(-50%);
  width: 280px;
  height: 280px;
  z-index: 0;
  opacity: 0.25;
  filter: drop-shadow(0 30px 60px rgba(255, 43, 80, 0.3));
}
.fiber line {
  stroke: url(#fiberGrad);
  stroke-width: 3;
  stroke-linecap: round;
  filter: drop-shadow(0 0 7px rgba(255, 43, 80, 0.6));
}
.hero-content {
  position: relative;
  z-index: 1;
}
.hero h2 {
  margin: 0;
  font-size: 34px;
  letter-spacing: -1.2px;
}
.hero h2 span {
  color: var(--magenta);
}
.hero p {
  font-size: 16px;
  color: var(--muted);
  margin: 8px 0 20px;
}
.hero-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  position: relative;
  z-index: 2;
}
.kpi-card {
  background: rgba(8, 14, 26, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  padding: 15px;
  box-shadow: 0 12px 25px rgba(50, 0, 90, 0.08);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  gap: 12px;
}
.kpi-icon {
  width: 44px;
  height: 44px;
  border-radius: 15px;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 20px;
  background: linear-gradient(135deg, var(--morado), var(--magenta));
}
.kpi-card small {
  display: block;
  color: var(--muted);
  font-size: 12px;
}
.kpi-card strong {
  display: block;
  font-size: 22px;
  margin-top: 2px;
}
.kpi-card em {
  font-style: normal;
  color: var(--success);
  font-size: 11px;
  font-weight: 800;
}
.kpi-card em.down {
  color: var(--magenta);
}

.section {
  background: rgba(7, 13, 24, 0.94);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: var(--shadow);
  margin-top: 18px;
}
.section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}
.section-head h3 {
  margin: 0;
  font-size: 16px;
  text-transform: uppercase;
  letter-spacing: 0.2px;
}
.link-btn {
  border: 0;
  background: transparent;
  color: var(--magenta);
  font-weight: 900;
  font-size: 13px;
}

.modules {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
}
.module {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 18px;
  padding: 16px;
  text-align: left;
  min-height: 178px;
  transition: 0.22s ease;
  position: relative;
  overflow: hidden;
}
.module:before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255, 43, 80, 0.06), transparent);
  opacity: 0;
  transition: 0.2s;
}
.module:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 43, 80, 0.35);
  box-shadow: 0 18px 35px rgba(50, 0, 90, 0.11);
}
.module:hover:before {
  opacity: 1;
}
.module-icon {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 20px;
  margin-bottom: 12px;
  box-shadow: 0 12px 25px rgba(50, 0, 90, 0.16);
}
.module h4 {
  margin: 0 0 7px;
  font-size: 14px;
}
.module p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
  min-height: 50px;
}
.module .go {
  display: inline-flex;
  margin-top: 13px;
  color: var(--magenta);
  font-weight: 900;
  font-size: 12px;
  align-items: center;
  gap: 6px;
}
.module.active {
  border-color: var(--magenta);
  box-shadow: 0 0 0 3px rgba(255, 43, 80, 0.09);
}
.grad-1 {
  background: linear-gradient(135deg, #7b1fff, var(--morado));
}
.grad-2 {
  background: linear-gradient(135deg, var(--magenta), #7b1fff);
}
.grad-3 {
  background: linear-gradient(135deg, #27c443, #60d739);
}
.grad-4 {
  background: linear-gradient(135deg, #2d89ff, #65b2ff);
}
.grad-5 {
  background: linear-gradient(135deg, #ff7a1a, var(--magenta));
}
.grad-6 {
  background: linear-gradient(135deg, #f2b600, #ffce47);
}
.grad-7 {
  background: linear-gradient(135deg, #00a3d9, #2d89ff);
}
.grad-8 {
  background: linear-gradient(135deg, var(--morado), #7b1fff);
}
.grad-9 {
  background: linear-gradient(135deg, #2eb77f, #4ed79d);
}
.grad-10 {
  background: linear-gradient(135deg, #5a1dd6, #a651ff);
}

.monthly {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}
.metric {
  background: rgba(9, 17, 32, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  padding: 16px;
  overflow: hidden;
}
.metric small {
  color: var(--morado);
  font-weight: 800;
}
.metric strong {
  display: block;
  font-size: 24px;
  margin: 6px 0;
}
.metric span {
  font-size: 12px;
  color: var(--success);
  font-weight: 800;
}
.spark {
  height: 42px;
  width: 100%;
  margin-top: 5px;
}
.spark polyline {
  fill: none;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.spark.magenta polyline {
  stroke: var(--magenta);
}
.spark.purple polyline {
  stroke: #7b1fff;
}
.spark.green polyline {
  stroke: var(--success);
}
.spark.blue polyline {
  stroke: var(--blue);
}

.bottom-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-bottom: 1px solid var(--line);
  padding: 10px 0;
}
.row:last-child {
  border-bottom: 0;
}
.row-left {
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
}
.file-icon {
  width: 30px;
  height: 30px;
  border-radius: 10px;
  background: #fff0f4;
  color: var(--magenta);
  display: grid;
  place-items: center;
  font-weight: 900;
}
.row strong {
  font-size: 13px;
}
.row small {
  display: block;
  color: var(--muted);
  font-size: 11px;
  margin-top: 2px;
}
.badge {
  font-size: 10px;
  font-weight: 900;
  border-radius: 999px;
  padding: 4px 7px;
  background: #ffe9ef;
  color: var(--magenta);
  white-space: nowrap;
}
.badge.blue {
  background: #eaf2ff;
  color: var(--blue);
}
.badge.green {
  background: #e7fff5;
  color: var(--success);
}

.right-col {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.panel {
  background: rgba(9, 17, 32, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
}
.panel h3 {
  margin: 0;
  font-size: 15px;
  text-transform: uppercase;
}
.notice {
  display: flex;
  gap: 13px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}
.notice:last-child {
  border-bottom: 0;
}
.notice .ni {
  width: 40px;
  height: 40px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 18px;
  flex: 0 0 auto;
}
.notice strong {
  font-size: 13px;
}
.notice p {
  margin: 4px 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}
.notice time {
  font-size: 11px;
  color: var(--muted);
}
.quick a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  font-weight: 800;
  font-size: 13px;
}
.quick a:last-child {
  border-bottom: 0;
}
.quick span {
  display: flex;
  align-items: center;
  gap: 10px;
}
.quick i {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #f2e9ff;
  color: var(--morado);
  font-style: normal;
}
.support {
  background: linear-gradient(135deg, var(--morado), var(--magenta));
  color: #fff;
  border: 0;
  position: relative;
  overflow: hidden;
}
.support:after {
  content: "🎧";
  position: absolute;
  right: 18px;
  bottom: 4px;
  font-size: 88px;
  opacity: 0.22;
}
.support h3 {
  text-transform: none;
  font-size: 20px;
}
.support p {
  color: rgba(255, 255, 255, 0.8);
  font-size: 13px;
  max-width: 250px;
}
.support button {
  border: 0;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
  font-weight: 1000;
  padding: 11px 16px;
}
.network .net-row {
  display: flex;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}
.network .net-row:last-child {
  border: 0;
}
.net-row span:last-child {
  color: var(--success);
  font-weight: 900;
}
.donut {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: conic-gradient(var(--success) 0 100%, #e8e1f0 0);
  display: grid;
  place-items: center;
  margin: 16px auto 6px;
}
.donut div {
  width: 82px;
  height: 82px;
  border-radius: 50%;
  background: #08101d;
  display: grid;
  place-items: center;
  font-size: 25px;
  font-weight: 1000;
  color: #fff;
}

.module-detail {
  display: none;
}
.module-detail.open {
  display: block;
}
.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-bottom: 14px;
}
.tab {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
  font-weight: 900;
  border-radius: 999px;
  padding: 9px 12px;
}
.tab.active {
  background: var(--magenta);
  color: #fff;
  border-color: var(--magenta);
}
.doc-view {
  background: rgba(9, 17, 32, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  padding: 18px;
}
.doc-view h4 {
  margin: 0 0 10px;
}
.doc-view p {
  color: var(--muted);
  line-height: 1.55;
}
.doc-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.doc-actions button {
  border: 0;
  border-radius: 13px;
  padding: 10px 14px;
  font-weight: 900;
}
.primary {
  background: var(--magenta);
  color: #fff;
}
.secondary {
  background: #f4ecff;
  color: var(--morado);
}

.mobile-backdrop {
  display: none;
}
body.sidebar-open .mobile-backdrop {
  display: block;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 15;
}

@media (max-width: 1380px) {
  .modules {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .hero-kpis {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
  .right-col {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .right-col .support,
  .right-col .network {
    grid-column: auto;
  }
}
@media (max-width: 980px) {
  .app {
    grid-template-columns: 1fr;
  }
  .sidebar {
    position: fixed;
    left: -310px;
    transition: 0.25s ease;
    width: 292px;
  }
  .sidebar.open {
    left: 0;
  }
  .menu-btn {
    display: block;
  }
  .profile small {
    display: none;
  }
  .hero {
    padding: 24px;
  }
  .fiber {
    display: none;
  }
  .monthly,
  .bottom-grid {
    grid-template-columns: 1fr;
  }
  .right-col {
    grid-template-columns: 1fr;
  }
  .modules {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 620px) {
  .main {
    padding: 14px;
  }
  .topbar {
    align-items: stretch;
  }
  .user-area {
    display: none;
  }
  .modules,
  .hero-kpis {
    grid-template-columns: 1fr;
  }
  .hero h2 {
    font-size: 28px;
  }
  .monthly {
    grid-template-columns: 1fr;
  }
  .section {
    padding: 14px;
  }
  .shortcut {
    display: none;
  }
  .search input {
    padding-right: 15px;
  }
  .bottom-grid {
    grid-template-columns: 1fr;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

.login-wrap {
  max-width: 420px;
  margin: 72px auto;
  padding: 28px;
  border-radius: 16px;
  background: rgba(9, 13, 24, 0.96);
  box-shadow: var(--shadow);
  color: var(--text);
}
.login-head {
  text-align: center;
  margin-bottom: 16px;
}
.login-head h1 {
  margin: 0;
  font-size: 20px;
}
.form-row {
  margin: 12px 0;
}
.form-row label {
  display: block;
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 6px;
}
.form-row input {
  width: 100%;
  padding: 10px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.02);
  color: var(--text);
}
.btn-primary {
  background: var(--magenta);
  color: #fff;
  border: 0;
  padding: 10px 14px;
  border-radius: 12px;
  width: 100%;
  font-weight: 900;
}
.hint {
  font-size: 12px;
  color: var(--muted);
  text-align: center;
  margin-top: 10px;
}
.error {
  color: #ffb6c5;
  font-weight: 700;
  margin-top: 8px;
  text-align: center;
}
