:root {
  --bg-a: #0a1a29;
  --bg-b: #10233c;
  --bg-c: #1b1120;
  --card: rgba(8, 21, 35, 0.88);
  --line: rgba(122, 180, 238, 0.24);
  --text: #e9f3ff;
  --muted: #97b4d3;
  --accent: #15ca8d;
  --accent-2: #5db6ff;
  --danger: #ea4f55;
  --warn: #ff8a34;
  --shadow: 0 22px 52px rgba(0, 0, 0, 0.35);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  position: relative;
  overflow-x: hidden;
  color: var(--text);
  font-family: "Sora", system-ui, sans-serif;
  background:
    radial-gradient(1200px 700px at -10% -15%, #24587a 0%, transparent 55%),
    radial-gradient(900px 620px at 110% 0%, #4a2e15 0%, transparent 52%),
    linear-gradient(160deg, var(--bg-a), var(--bg-b) 52%, var(--bg-c));
}

.bg-orb {
  position: fixed;
  border-radius: 999px;
  opacity: 0.16;
  filter: blur(8px);
  pointer-events: none;
  z-index: 0;
}

.orb-a {
  width: 360px;
  height: 360px;
  right: -120px;
  top: 12%;
  background: #21e5bf;
  animation: floatY 12s ease-in-out infinite;
}

.orb-b {
  width: 280px;
  height: 280px;
  left: -100px;
  bottom: 8%;
  background: #58a4ff;
  animation: floatY 14s ease-in-out infinite reverse;
}

.layout {
  position: relative;
  z-index: 1;
  max-width: 1240px;
  margin: 0 auto;
  padding: 30px 18px 50px;
}

.hero {
  margin-bottom: 18px;
  animation: rise 380ms ease-out;
}

.hero h1 {
  margin: 0 0 8px;
  font-size: clamp(1.6rem, 2.4vw, 2.8rem);
  letter-spacing: 0.01em;
}

.hero p {
  margin: 0;
  color: var(--muted);
}

.eyebrow {
  margin: 0 0 10px;
  color: #8dd8ff;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  font-size: 0.76rem;
}

.card {
  margin-bottom: 14px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--card);
  box-shadow: var(--shadow);
  backdrop-filter: blur(8px);
  animation: rise 340ms ease-out;
}

.card.slim {
  padding: 12px 16px;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.stack {
  display: grid;
  gap: 10px;
}

.grid-two {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.customer-grid {
  display: grid;
  grid-template-columns: minmax(260px, 320px) minmax(0, 1fr);
  gap: 14px;
}

label {
  display: grid;
  gap: 6px;
  font-size: 0.92rem;
}

.toggle-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid rgba(151, 180, 211, 0.2);
  background: rgba(6, 15, 26, 0.68);
}

.toggle-row input[type="checkbox"] {
  width: auto;
}

input,
select,
textarea,
button {
  font: inherit;
  border-radius: 10px;
}

input,
select,
textarea {
  width: 100%;
  color: var(--text);
  border: 1px solid rgba(151, 180, 211, 0.25);
  background: rgba(5, 12, 22, 0.72);
  padding: 10px 12px;
}

textarea {
  resize: vertical;
}

button {
  border: 1px solid transparent;
  padding: 10px 13px;
  color: #081018;
  font-weight: 700;
  background: linear-gradient(120deg, var(--accent), #7ce9ff);
  cursor: pointer;
  transition: transform 0.12s ease, filter 0.12s ease;
}

button:hover {
  transform: translateY(-1px);
  filter: brightness(1.06);
}

button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

button.ghost {
  color: var(--text);
  border-color: rgba(151, 180, 211, 0.35);
  background: transparent;
}

button.danger {
  color: #fff;
  background: linear-gradient(120deg, #f16b69, var(--danger));
}

button.warn {
  color: #fff;
  background: linear-gradient(120deg, #ffb04b, var(--warn));
}

button.accent {
  color: #031019;
  background: linear-gradient(120deg, #14cd8f, #35f0c4);
}

.hidden {
  display: none !important;
}

h2,
h3 {
  margin: 0 0 10px;
}

.muted {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.notice {
  border-color: rgba(91, 182, 255, 0.55);
  background: rgba(53, 110, 173, 0.18);
  color: #d6ebff;
}

.notice.error {
  border-color: rgba(234, 79, 85, 0.6);
  background: rgba(234, 79, 85, 0.14);
  color: #ffd0d2;
}

.row-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.table-wrap {
  overflow: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
  min-width: 700px;
}

th,
td {
  text-align: left;
  padding: 9px 10px;
  border-bottom: 1px solid rgba(151, 180, 211, 0.18);
  vertical-align: top;
}

th {
  color: #b6d6f8;
  font-weight: 700;
}

.pill {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.pill.locked {
  background: rgba(234, 79, 85, 0.2);
  color: #ffb8bb;
}

.pill.ok {
  background: rgba(21, 202, 141, 0.2);
  color: #abf7dc;
}

.server-list {
  display: grid;
  gap: 8px;
}

.server-item {
  border: 1px solid rgba(151, 180, 211, 0.2);
  border-radius: 10px;
  background: rgba(6, 15, 26, 0.76);
  padding: 10px;
  cursor: pointer;
}

.server-item.active {
  border-color: #3ecbf8;
  box-shadow: inset 0 0 0 1px rgba(62, 203, 248, 0.35);
}

.server-item h4 {
  margin: 0 0 6px;
}

.server-item p {
  margin: 2px 0;
  color: var(--muted);
  font-size: 0.84rem;
}

.action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-bottom: 12px;
}

.soft-box {
  border: 1px solid rgba(151, 180, 211, 0.2);
  border-radius: 12px;
  background: rgba(2, 12, 22, 0.58);
  padding: 12px;
}

.soft-box p {
  margin: 6px 0;
}

.credential-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.eye-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  padding: 0;
  color: #cfe8ff;
  border: 1px solid rgba(151, 180, 211, 0.35);
  border-radius: 10px;
  background: rgba(6, 15, 26, 0.78);
}

.eye-toggle:hover {
  color: #ffffff;
  border-color: rgba(151, 180, 211, 0.55);
  background: rgba(7, 20, 34, 0.95);
}

.eye-toggle:disabled {
  opacity: 0.42;
}

.eye-icon {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.eye-slash {
  opacity: 1;
}

.eye-toggle.revealed .eye-slash {
  opacity: 0;
}

.usage-item {
  display: grid;
  grid-template-columns: auto auto;
  gap: 6px 10px;
  margin-bottom: 9px;
}

.usage-track {
  grid-column: 1 / -1;
  height: 8px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(151, 180, 211, 0.18);
}

.usage-fill {
  height: 100%;
  width: 0;
  background: linear-gradient(120deg, #2ce19b, #57d8ff);
}

#serverMetaGrid {
  grid-template-columns: 1fr;
}

#monitoringUsageBox {
  min-height: 220px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 10px;
}

#monitoringUsageBox .usage-item {
  margin-bottom: 0;
}

#monitoringUsageBox .usage-track {
  height: 12px;
}

.chart-wrap {
  margin-top: 14px;
  border: 1px solid rgba(151, 180, 211, 0.2);
  border-radius: 12px;
  background: rgba(5, 13, 23, 0.65);
  padding: 10px;
  height: 220px;
}

.inline-form {
  display: flex;
  gap: 8px;
  align-items: center;
}

.inline-form input {
  min-width: 190px;
}

#statusPageLinkWrap {
  margin-top: 10px;
}

#statusPageLink {
  color: #9ad9ff;
  word-break: break-all;
}

.list-stack {
  display: grid;
  gap: 10px;
}

.list-card {
  border: 1px solid rgba(151, 180, 211, 0.2);
  border-radius: 12px;
  background: rgba(6, 15, 24, 0.72);
  padding: 11px 12px;
}

.list-card p {
  margin: 4px 0;
}

.weekday-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.weekday-grid label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 8px;
  border-radius: 8px;
  background: rgba(9, 21, 36, 0.75);
  border: 1px solid rgba(151, 180, 211, 0.2);
}

.lock-banner {
  margin-bottom: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(234, 79, 85, 0.5);
  background: rgba(234, 79, 85, 0.16);
  color: #ffc7c9;
}

.locked-only {
  border-color: rgba(234, 79, 85, 0.6);
  background: linear-gradient(120deg, rgba(234, 79, 85, 0.18), rgba(24, 12, 19, 0.92));
}

code,
pre {
  font-family: "JetBrains Mono", monospace;
}

pre {
  margin: 0;
  min-height: 180px;
  border-radius: 10px;
  border: 1px solid rgba(151, 180, 211, 0.2);
  background: #040a12;
  color: #cce8ff;
  padding: 12px;
  overflow: auto;
  line-height: 1.42;
  font-size: 0.84rem;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes floatY {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-16px);
  }
}

@media (max-width: 980px) {
  .customer-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .layout {
    padding: 18px 12px 36px;
  }

  .grid-two {
    grid-template-columns: 1fr;
  }

  .inline-form {
    flex-direction: column;
    align-items: stretch;
  }

  .hero h1 {
    font-size: 1.55rem;
  }
}
