:root {
  --primary-color: #ff6b6b;
  --secondary-color: #e7e7e7;
  --bg-color: #0a0a0a;
  --card-bg: #1a191c;
  --border-color: #333333;
  --text-color: #e0e0e0;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Montserrat', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  background-color: var(--bg-color);
  color: var(--text-color);
  -webkit-font-smoothing: antialiased;
}

a {
  text-decoration: none;
  color: inherit;
}

.wrapper {
  max-width: 1350px;
  margin: 20px auto;
  display: flex;
  gap: 20px;
  padding: 0 20px;
}

.left-column {
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: 275px;
  flex-shrink: 0;
}

.sidebar {
  padding: 20px;
  background-color: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 15px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.3);
  width: 100%;
  background-image: url('/assets/images/bg.png');
  background-repeat: no-repeat;
  background-size: contain;
}

.sidebar .logo img {
  display: block;
  margin: 0 auto;
  max-width: 70%;
  height: auto;
  transition: transform 0.3s ease-in-out;
  transform-origin: center;
  padding: 5px 0px 15px 0px;
}

.sidebar .logo img:hover {
  transform: scale(1.04);
}


.menu-item {
  display: flex;
  align-items: center;
  padding: 10px 12px;
  border-radius: 15px;
  transition: background-color 0.5s;
  cursor: pointer;
  color: var(--secondary-color);
  margin-bottom: 5px;
  font-weight: 500;
}

.menu-item:hover {
  background-color: #262629;
  transition: background-color 0.4s;
}

.menu-item.active {
  font-weight: 600;
  color: var(--text-color);
  background-color: #262629;
}

.menu-item:nth-child(1) i {
  font-family: "Font Awesome 5 Free"; 
  font-weight: 900;
  content: "\f201"; /* fa-chart-line */
}

.menu-item i {
  font-size: 16px;
  width: 35px;
  text-align: center;
}

.menu-item span {
  font-size: 14px;
  margin-left: 5px;
}

.sidebar-img {
  background-color: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 15px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  text-align: center;
  padding: 6px;
}

.sidebar-img img {
  width: 100%;
  border-radius: 10px;
}

.content {
  flex: 4.5;
  padding: 20px;
  background-color: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 15px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.3);
  }

.stats {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
}

.stat-item {
  flex: 1;
  border-radius: 15px;
  padding: 15px;
  text-align: center;
  transition: transform 0.2s;
  color: #fff;
}

.stat-item:hover {
  transform: translateY(-3px);
}

.stat-day {
  background: radial-gradient(50% 80% at 50% 0%, rgb(113 113 113 / 56%) 0%, #242424 100%), radial-gradient(20% 35% at 50% 0%, rgb(137 137 137 / 70%) 0%, #242424 100%);
  animation: pulseGlow 2s infinite ease-in-out;
  border: 1px solid var(--border-color);
  background-color: #262629;
  background-image: url(/assets/images/bg.png);
  background-repeat: no-repeat;
  background-size: contain;
}

.stat-day:hover {
  background: radial-gradient(50% 80% at 50% 0%, rgb(113 113 113 / 56%) 0%, #242424 100%), radial-gradient(20% 35% at 50% 0%, rgb(137 137 137 / 70%) 0%, #242424 100%);
  animation: pulseGlow 2s infinite ease-in-out;
  border: 1px solid var(--border-color);
}

.stat-week {
  background: radial-gradient(50% 80% at 50% 0%, rgb(76 175 80 / 56%) 0%, #242424 100%), radial-gradient(20% 35% at 50% 0%, rgb(76 175 80 / 70%) 0%, #242424 100%);
  animation: pulseGlow 2s infinite ease-in-out;
  border: 1px solid var(--border-color);
  background-color: #262629;
  background-image: url(/assets/images/bg.png);
  background-repeat: no-repeat;
  background-size: contain;
}

.stat-week:hover {
  background: radial-gradient(50% 80% at 50% 0%, rgb(76 175 80 / 56%) 0%, #262629 100%), radial-gradient(20% 35% at 50% 0%, rgb(76 175 80 / 70%) 0%, #262629 100%);
  animation: pulseGlow 2s infinite ease-in-out;
  border: 1px solid var(--border-color);
}

.stat-month {
  background: radial-gradient(50% 80% at 50% 0%, rgb(255 196 0 / 38%) 0%, #262629 100%), radial-gradient(20% 35% at 50% 0%, rgb(255 196 0 / 44%) 0%, #262629 100%);
  animation: pulseGlow 2s infinite ease-in-out;
  border: 1px solid var(--border-color);
  background-color: #262629;
  background-image: url(/assets/images/bg.png);
  background-repeat: no-repeat;
  background-size: contain;
}

.stat-month:hover {
  background: radial-gradient(50% 80% at 50% 0%, rgb(255 196 0 / 38%) 0%, #262629 100%), radial-gradient(20% 35% at 50% 0%, rgb(255 196 0 / 44%) 0%, #262629 100%);
  animation: pulseGlow 2s infinite ease-in-out;
  border: 1px solid var(--border-color);
}

.stat-year {
  background: radial-gradient(50% 80% at 50% 0%, rgb(255 56 90 / 46%) 0%, #242424 100%), radial-gradient(20% 35% at 50% 0%, rgb(255 56 90 / 42%) 0%, #242424 100%);
  animation: pulseGlow 2s infinite ease-in-out;
  border: 1px solid var(--border-color);
  background-color: #262629;
  background-image: url(/assets/images/bg.png);
  background-repeat: no-repeat;
  background-size: contain;
}

.stat-year:hover {
  background: radial-gradient(50% 80% at 50% 0%, rgb(255 56 90 / 46%) 0%, #262629 100%), radial-gradient(20% 35% at 50% 0%, rgb(255 56 90 / 42%) 0%, #262629 100%);
  animation: pulseGlow 2s infinite ease-in-out;
  border: 1px solid var(--border-color);
}

.stats .stat-year h4  {
  color: #ff385a;
}
.stats .stat-month h4  {
  color: #ffc400;
}
.stats .stat-week h4  {
  color: #4caf50;
}
.stat-item h4 {
  font-size: 12px;
  margin-bottom: 5px;
  font-weight: 600;
  color: #bbbbbb;
}

.stat-item p {
  font-size: 18px;
  font-weight: 700;
}

.deposits h3 {
  font-size: 14px;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-color);
  font-weight: 600;
}

.deposits-container {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.deposit-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px;
  background-color: #262629;
  border-radius: 15px;
  transition: background-color 0.4s;
  border: 1px solid #333333ba;
}

.deposit-item:hover {
  background-color: #2b2a2d;
}

.deposit-info {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.deposit-info span {
  font-size: 14px;
  color: var(--secondary-color);
  font-weight: 500;
}

.deposit-status {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 5px;
}
.status-button {
  border-radius: 15px;
  font-size: 14px;
  cursor: pointer;
  padding: 3px 12px;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 5px;

  border:none;
  background-color: transparent;        
  color: var(--status-color);         
}

.status-button:hover {
  background-color: var(--status-color) !important; 
  color: #000000 !important;                      
  box-shadow: 0 0 10px var(--status-color);       
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 500;
}

.status-paid { 
    --status-color: #27ae60; 
    color: var(--status-color); 
}
.status-pending { 
    --status-color: #ffc400; 
    color: var(--status-color); 
}
.status-overdue { 
    --status-color: #ff385a; 
    color: var(--status-color); 
}
.status-refund { 
    --status-color: #9b59b6; 
    color: var(--status-color); 
}
.status-canceled { 
    --status-color: #95a5a6; 
    color: var(--status-color); 
}

.status-paid.status-badge {
  background-color: rgba(76, 175, 80, 0.2);
}
.status-paid.status-badge.time {
    background: none;
    padding: 0px;
}


.status-pending.status-badge {
  background-color: #ffc40030;
}
.status-pending.status-badge.time {
  background: none;
  padding: 0px;
}


.status-overdue.status-badge {
  background: rgba(231, 76, 60, 0.1);
}
.status-overdue.status-badge.time {
  background: none;
  padding: 0px;
}


.status-refund.status-badge {
  background-color: rgba(155, 89, 182, 0.2);
}
.status-refund.status-badge.time {
  background: none;
  padding: 0px;
}


.status-canceled.status-badge {
  background-color: rgba(149, 165, 166, 0.2);
}
.status-canceled.status-badge.time {
  background: none;
  padding: 0px;
}

.fa-spin {
  animation: fa-spin 2s infinite linear;
}

.deposit-amount {
  font-size: 16px;
  font-weight: 600;
}


.right-panel {
  width: 300px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.sidebar {
  background-color: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 15px;
  padding: 15px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.sidebar h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 15px;
  display: flex;
  align-items: center;
  gap: 5px;
  color: var(--text-color);
}

.sidebar.balance {
  background: radial-gradient(50% 80% at 50% 100%, rgb(180 241 142 / 20%) 0%, rgb(30 30 30) 100%), 
              radial-gradient(20% 35% at 50% 100%, rgb(180 241 142 / 29%) 0%, rgb(98 203 57 / 16%) 100%);
  color: #fff;
  border: none;
  box-shadow: 0 4px 8px rgba(0,0,0,0.5);
  padding: 20px;
  border-radius: 15px;
  text-align: center;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border-color);
  background: radial-gradient(120% 120% at 50% 100%, #1e1e1e 40%, #63e 70%, #fff 100%);
}

.sidebar.balance .balance-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 600;
}

.sidebar.balance .balance-amount {
  font-size: 24px;
  font-weight: 700;
  padding-bottom: 15px;
}

.withdraw-button {
  display: inline-block;
  padding: 10px 20px;
  background: #ffffff;
  color: #000000;
  border: 1px solid #505050;
  border-radius: 15px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.2s, color 0.2s;
}

.withdraw-button:hover {
  background: #ffffffd9;
}

.sidebar.support {
  background-color: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 15px;
  padding: 15px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.sidebar.support h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 10px;
  color: var(--text-color);
}

.support-links {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.support-links a {
  font-size: 13px;
  color: #63616a;
  transition: color 0.2s;
}

.support-links a:hover {
  color: #88868f;
}

.sidebar.language select {
  width: 100%;
  padding: 10px;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  background-color: var(--card-bg);
  color: var(--text-color);
  font-size: 14px;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: url('data:image/svg+xml;charset=US-ASCII,<svg xmlns="http://www.w3.org/2000/svg" width="12" height="12" fill="%23bbbbbb"><polygon points="0,0 12,0 6,6"/></svg>');
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 12px;
}

.action-buttons {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
}

.action-button {
  color: #cdcad3;
  background: #262629;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 14px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  transition: background-color 0.2s, opacity 0.2s, transform 0.2s;
  user-select: none;
  white-space: nowrap;
  font-family: 'Montserrat', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  border: none;
}

  .action-button:hover {
    transform: translateY(-1px);
    background: #333333;
  }
  .action-button:active { transform: translateY(0px); opacity: 0.95; }
  .action-button[disabled] { opacity: 0.45; cursor: not-allowed; transform: none; }


.action-button-2 {
  background: #ffffff;
  color: #000000;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 14px;
  border: 1px solid var(--border-color);
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  transition: background-color 0.2s, opacity 0.2s, transform 0.2s;
  user-select: none;
  font-family: 'Montserrat', 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

.action-button-2:hover {
  opacity: 0.9;
}

.action-button-2:hover { transform: translateY(-1px); }
.action-button-2:active { transform: translateY(1px); opacity: 0.95; }

.action-button i {
  margin-right: 5px;
}

.action-button-2 i {
  margin-right: 5px;
}

.server-list {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.server-item {
  background: #262629;
  border: 1px solid var(--border-color);
  border-radius: 15px;
  /* padding: 15px; */
}

.server-item h3 {
  font-size: 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  padding: 15px;
  border-radius: 15px 15px 0 0;
  background: #2b2a2d;
}

.server-actions {
  display: flex;
  gap: 10px;
  padding: 15px;
}

.server-actions .action-button {
  flex: 1;
  justify-content: center;
  padding: 10px;
}

.action-buttons .action-button {
  background: #262629;
  color: #e7e7e7;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 14px;
  border: 1px solid var(--border-color);
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  transition: background-color 0.2s, opacity 0.2s, transform 0.2s;
  user-select: none;
  font-family: 'Montserrat', 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

.action-buttons .action-button:hover {
  background: #2f2f32;
}

.action-buttons .action-button:hover { transform: translateY(-1px); }
.action-buttons .action-button:hover { transform: translateY(-1px); opacity: 0.95; }


lord-icon {
  margin: 0px 5px;
}

.deposit-date i {
  color: #7b7780;
  padding-right: 5px;
}

.deposit-user i {
  color: #7b7780;
  padding-right: 5px;
}

.deposit-steamid i {
  color: #7b7780;
  padding-right: 5px;
}

.deposit-info .deposit-date {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 400px;
}

.time-pay {
  color: #6e6e6e;
}

.loading {
  background: #262629;
  border: 1px solid #333333ba;
  display: flex;
  align-items: center;
  justify-content: center;
}

.loading:hover {
  background: #2b2a2d;
}

#modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(4px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

#modal-overlay .modal {
  background: #1a191c;
  width: 400px;
  max-width: 90%;
  position: relative;
  text-align: center;
  padding: 30px;
  background-color: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 15px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  background-image: url(/assets/images/bg.png);
  background-repeat: no-repeat;
  background-size: contain;
  background: radial-gradient(50% 80% at 50% 0%, rgb(70 56 255 / 27%) 0%, #1a191c 100%), radial-gradient(20% 35% at 50% 0%, rgb(255 56 217 / 26%) 0%, #1a191c 100%);
  top: -15%;
}

.modal-image {
  width: 130px;
  margin-top: -10px;
  display: inline-block;
  transform-origin: top center;
  animation: swing 7s ease-in-out infinite;
}

    @keyframes swing {
      0%   { transform: rotate(0deg); }
      25%  { transform: rotate(5deg); }
      75%  { transform: rotate(-5deg); }
      100% { transform: rotate(0deg); }
    }

.close-btn {
  position: absolute;
  top: 10px;
  right: 15px;
  border: none;
  background: transparent;
  font-size: 30px;
  cursor: pointer;
  color: #7b7780;
}

.close-btn:hover {
  color: #9b96a1;
}

.modal-btn {
  display: inline-flex;
  gap: 8px;
  margin: 10px auto;
  align-items: center;
  padding: 10px 15px;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  font-size: 14px;
  transition: background-color 0.2s;
  /* width: 250px; */
}

.plugin-btn {
  color: #cdcad3;
  background: #262629;
  border: 1px solid var(--border-color);
}

.plugin-btn:hover {
  color: #e7e5ec;
  background: #2e2d31;
}

.check-btn {
  background-color: #eeeeee;
  color: #000000;
}

.check-btn:hover {
  opacity: 0.9;
}


.modal-text {
  font-size: 14px;
  margin-top: 10px;
}


  .subs-container { display:flex; flex-direction:column; align-items:center; width:100%; max-width:1000px; }
  /* Toggle Period */
  .period-switch {position:relative;display:flex;background: #262629;border-radius:50px;overflow:hidden;width:300px;border: 1px solid var(--border-color);}
  .period-switch input { display:none; }
  .period-switch label {flex:1;padding: 6px 0 10px 0;text-align:center;cursor:pointer;font-size:14px;color:#777;z-index:1;transition:color .3s;}
  .period-switch::before {content:'';position:absolute;top:4px;bottom:4px;left:var(--ind-left);width:calc(50% - 8px);background: #3f3e43;border-radius:50px;transition: left .6s;}
  #period-year:checked ~ .period-switch label[for="period-year"], #period-month:checked ~ .period-switch label[for="period-month"] { color:#fff; }
  .discount-tag {font-size:12px;margin-left:8px;background: #ff385a;padding: 2px 5px;border-radius: 50px;color: #ffffff;}
  /* Cards Grid */
  .cards {display:grid;grid-template-columns:repeat(auto-fit, minmax(280px,1fr));gap: 15px;width:100%;margin-top: 15px;}
  .card {display:flex;flex-direction:column;border-radius:16px;padding:24px;transition:transform .3s,box-shadow .3s;cursor:pointer;border: 1px solid var(--border-color);}
  .card:hover { transform:translateY(-3px); box-shadow:0 12px 24px rgb(0 0 0 / 36%); }
  .card.selected {outline: 3px solid #262629;outline-offset:-3px;}
  .card.start {background: #262629;}
  .card.pro {background: #262629;}
  .card.free .old { display:none; }
  .card h3 {font-size: 24px;font-weight:700;margin-bottom:16px;}
  .card .price { display:flex; align-items:flex-end; gap:8px; margin-bottom:16px; }
  .card .price .old {text-decoration: line-through solid #ff4d4f 2px;font-size: 18px;}
  .card .price .new {font-size: 24px;font-weight:700;}
  .card .price .period {font-size:1rem;color:rgba(255,255,255,0.7);margin-left: -5px;}
  .card .features { list-style:none; display:flex; flex-direction:column; gap:8px; flex-grow:1; margin-bottom:16px; }
  .card .features li { display:flex; align-items:center; font-size:14px; }
  .card .features li::before { content:'\2713'; margin-right:8px; color:rgba(255,255,255,0.6); font-size:12px; }
  .card button {margin-top:auto;width:100%;transition:background .3s;display: inline-block;padding: 12px 20px;background: #ffffff;color: #000000;border: 1px solid #505050;border-radius: 15px;font-size: 14px;cursor: pointer;font-weight: 500;}
  /* .card.currentPlan button {background: #262629;color:#777;border:1px solid #333;} */
  .card.disabled button {background: #262629;color:#777;border:1px solid #333;}
  .card.start button:hover, .card.pro button:hover { opacity:0.9; }
  

    .subskribe {
    background: #1a191c;
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 15px;
    padding: 20px;
  }

  /* ==== HEADER ==== */
  .card__header {
    display: flex;
    align-items: center;
  }
  .card__title {
    font-size: 24px;
    font-weight: 600;
    color: #ffffff;
    line-height: 1;
  }
  .card__upgrade {
    align-items: center;
    margin-left: 15px;
    font-size: 14px;
    color: #c2c2c2;
    cursor: pointer;
  }

  .card__upgrade:hover {
    color: #d9d9d9;
}
  .card__upgrade svg {
    width: 20px;
    height: 20px;
    margin-right: 4px;
    fill: currentColor;
  }

  /* ==== LABEL ==== */
  .card__label {
    margin-top: 8px;
    font-size: 14px;
    color: #c2c2c2;
    line-height: 1;
  }

  /* ==== BUTTON ==== */
  .card__btn {
    align-items: center;
    width: 100%;
    transition: background .3s;
    display: inline-block;
    padding: 12px 20px;
    background: #262629;
    color: #e7e7e7;
    border-radius: 15px;
    font-size: 14px;
    cursor: pointer;
    font-weight: 500;
    margin-top: 20px;
    border: 1px solid var(--border-color);
    font-family: 'Montserrat', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  }

  .card__btn:hover {
    background: #2f2f32;
  }
  .card__btn svg {
    width: 24px;
    height: 24px;
    margin-right: 8px;
    fill: currentColor;
  }

  .fa-star {
    font-size: 12px;
  }

  .card__progress {
    margin-top: 16px;
    width: 100%;
    height: 7px;
    background: #262629;
    border-radius: 4px;
    overflow: hidden;
}

.card__progress-fill {
    width: 10%;
    height: 100%;
    background: linear-gradient(to right, #ffffff, #6234ff);
    border-radius: 5px;
}

  /*referral*/
      .refsys-container {
      max-width: 800px;
      width: 100%;
      display: flex;
      flex-direction: column;
      gap: 20px;
    }
    .refsys-block {
      /* background: #262629; */
      border-radius: 15px;
      /* padding: 20px; */
      box-shadow: 0 2px 8px rgba(0,0,0,0.1);
      /* border: 1px solid #333333; */
    }
  .refsys-blocks {
      background: #262629;
      border-radius: 15px;
      padding: 20px;
      box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
      border: 1px solid #333333;
  }
    .refsys-block__title {
      display: flex;
      align-items: center;
      gap: 8px;
      font-size: 14px;
      margin-bottom: 16px;
      font-weight: 600;
    }

.refsys-link-row {
      display: flex;
      gap: 12px;
      align-items: center;
    }
    .refsys-link-row__input {
      flex: 1;
      padding: 11px 15px;
      font-size: 0.95rem;
      background: #262629;
      border-radius: 15px;
      color: #737373;
      border: 1px solid #333333;
    }
    .refsys-link-row__button {
      align-items: center;
      gap: 6px;
      margin-top: auto;
      transition: background .3s;
      display: inline-block;
      padding: 12px 20px;
      color: #000000;
      border: 1px solid #505050;
      border-radius: 15px;
      font-size: 14px;
      cursor: pointer;
      font-weight: 500;
    }
    .refsys-link-row__button:hover {background: #ffffffd9;}
    .refsys-description {
      margin-top: 12px;
      color: #e4e4e4;
      font-size: 0.9rem;
    }

    .refsys-stats-grid {
      display: flex;
      gap: 12px;
      flex-wrap: wrap;
      justify-content: space-between;
    }
    .refsys-stat-box {
      flex: 1 1 30%;
      background: #262629;
      border-radius: 15px;
      padding: 16px;
      text-align: center;
      border: 1px solid #333333;
    }
    .refsys-stat-box i {font-size: 1.3rem;color: #888;}
    .refsys-stat-box__value {margin: 8px 0 4px;font-size: 16px;font-weight: 600;color: #ffffff;}
    .refsys-stat-box__label {font-size: 0.85rem;color: #9a9a9a;}

    .refsys-table {
      width: 100%;
      border-collapse: collapse;
      border-radius: 15px;
      overflow: hidden;
      box-shadow: 0 1px 4px rgba(0,0,0,0.1);
      border-collapse: separate;
      border-spacing: 0;
      border: 4px solid #262629;
    }
    .refsys-table thead {background: #262629;}

    .refsys-table th,
    .refsys-table td {
      padding: 12px;
      text-align: left;
      border-top: 2px solid #262629;
      font-size: 14px;
    }
    .refsys-table th {font-weight: 600;color: #ffffff;}
    .refsys-table tbody tr:hover { background: #fafafa; }
    .refsys-accent { color: #4caf50; font-weight: 600; }

    .refsys-pagination {
      display: flex;
      justify-content: center;
      gap: 8px;
      margin-top: 16px;
    }
    .refsys-page-btn {
      padding: 8px 12px;
      border-radius: 12px;
      cursor: pointer;
      font-size: 0.9rem;
      color: #ffffff;
      background: #262629;
      border: 1px solid #333333;
    }
    .refsys-page-btn:hover { background: #f0f0f0; color: #000000 }
    .refsys-page-btn.active {
      background: #ffffff;
      border-color: #ffffff;
      color: #000;
      font-weight: 600;
    }

    .refsys-how p {margin: 0 0 8px;font-size: 0.9rem;color: #a7a7a7;}
    .refsys-how h3 { margin: 8px 0; font-size: 1rem; }
    .refsys-how ul { margin: 4px 0 0 20px; color: #444; }
    /* ÃƒÂÃ‚ÂÃƒÂÃ‚Â´ÃƒÂÃ‚Â°ÃƒÂÃ‚Â¿Ãƒâ€˜Ã¢â‚¬Å¡ÃƒÂÃ‚Â¸ÃƒÂÃ‚Â² */
    @media (max-width: 600px) {
      .refsys-stats-grid { flex-direction: column; }
      .refsys-link-row { flex-direction: column; }
    }
    .refsys-table tbody tr:hover {background: #262629;}
  /*referral*/

      :root{
      /* palette from site */
      --primary-color: #ffffff;
      --secondary-color: #e7e7e7;
      --bg-color: #0a0a0a;
      --card-bg: #1a191c;
      --border-color: #333333;
      --text-color: #e0e0e0;
      --bg: var(--bg-color);
      --card: var(--card-bg);
      --text: var(--text-color);
      --muted: #9a9aa3;                  
      --primary: var(--primary-color);
      --primary-600: #e7e7e7;          
      --danger: #ff385a;
      --danger-700:#d43b3b;
      --success:#4caf50;
      --warning:#ffc400;
      --ring: 0 0 0 2px rgb(255 255 255 / .25);
      --radius: 14px;
      --gap: 14px;
    }

 

    .row>*{min-width:0}
    .stack>*{min-width:0}
    .stack>.input,.stack>.select{flex:1 1 0}
    .input,.select{width:100%;max-width:100%}


    .page-title{font-size:28px;font-weight:700;margin:0 0 18px}
    .sub{color:var(--muted);font-size:14px;margin-top:-6px;margin-bottom:22px}

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

    .cardt {
      background:var(--card);
      border:1px solid var(--border-color);
      border-radius:var(--radius);
      box-shadow:0 8px 30px rgb(0 0 0 / .25);
      overflow:hidden;
    }
    
    .cardt+.cardt {
      margin-top:var(--gap)
    }

    .cardt-h {
      display:flex;
      align-items:center;
      justify-content:space-between;
      padding:16px 18px;
      border-bottom:1px solid var(--border-color);
      background: #26262969;
    }

    .cardt-h h3 {
      margin:0;
      font-size: 16px;
      font-weight: 600;
    }

    .cardt-b {
      padding:18px
    }

    .cardt-f {
      padding:14px 18px;
      border-top:1px solid var(--border-color);
      display:flex;
      gap:10px;
      justify-content:flex-end
    }

    .row{display:grid;grid-template-columns:repeat(12,minmax(0,1fr));gap:12px}
    .col-12{grid-column:span 12}
    .col-6{grid-column:span 6}
    .col-4{grid-column:span 4}
    @media (max-width:760px){.col-6,.col-4{grid-column:span 12}}

    label{display:block;font-size:13px;color:var(--secondary-color);margin:8px 0 6px;}
    .input,.select{padding:12px 12px;border-radius:10px;background: #262629;border:1px solid var(--border-color);color:var(--text);outline:none;transition:.2s}
    .input:focus,.select:focus{box-shadow:var(--ring);border-color:rgb(255 255 255 / .18)}

    .stack{display:flex;gap:10px;align-items:center}
    .stack-col{display:flex;gap:10px;flex-direction:column}

    .btn{appearance:none;border:0;border-radius:10px;padding:10px 14px;cursor:pointer;font-weight:600;transition:transform .06s ease,background .2s}
    .btn:active{transform:translateY(1px)}
    .btn.primary{background:var(--primary);color:#000}
    .btn.primary:hover{background:var(--primary-600)}
    .btn.ghost{background:#262629;border:1px solid var(--border-color);color:#cdcad3}
    .btn.ghost:hover{background:#3f3e43}
    .btn.muted{background:#262629;color:#777;border:1px solid var(--border-color)}
    .btn.danger{background:var(--danger);color:#300}
    .btn.danger:hover{background:var(--danger-700)}

    .hint{font-size:12px;color:#a7a7a7}
    .badge{display:inline-flex;align-items:center;gap:6px;padding:2px 8px;border-radius:999px;font-size:12px;border:1px solid var(--border-color);background:#262629;color:var(--secondary-color)}
    .badge.success{border-color:rgba(76,175,80,.4);background:rgba(76,175,80,.2);color:#4caf50}
    .badge.warn{border-color:rgba(255,196,0,.35);background:rgba(255,196,0,.18);color:#ffc400}

    .section{margin-bottom:var(--gap)}
    .hr{height:1px;background:var(--border-color);margin:12px 0}

    .pw{position:relative}
    .pw .toggle{position:absolute;right:10px;top:50%;translate:0 -50%;color:#9a9aa3;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;width:34px;height:34px;border-radius:8px;border:1px solid transparent;background:transparent}
    .pw .toggle:hover{background:#262629;border-color:var(--border-color)}
    .pw .toggle i{font-size:15px}
    .pw input{padding-right:42px}

    .meter{height:8px;border-radius:999px;background:#262629;border:1px solid var(--border-color);overflow:hidden}
    .meter>i{display:block;height:100%;width:0;background:linear-gradient(90deg,#ef4444,#f59e0b,#22c55e);transition:width .25s}
    .meter-label{font-size:12px;color:#a7a7a7}

    .switch{--h:22px;--w:42px;position:relative;width:var(--w);height:var(--h);background:#262629;border:1px solid var(--border-color);border-radius:999px;cursor:pointer;display:inline-block;vertical-align:middle}
    .switch i{position:absolute;left:2px;top:2px;width:calc(var(--h) - 4px);height:calc(var(--h) - 4px);background:#fff;border-radius:50%;transition:left .2s}
    .switch[data-on="true"]{background:#fff;border-color:#fff} 
    .switch[data-on="true"] i{background:#000}
    .switch[data-on="true"] i{left:calc(var(--w) - var(--h) + 2px)}

    .danger-zone{border:1px solid rgba(255,56,90,.35);margin-bottom: 24px;}

    .table{width:100%;border-collapse:collapse}
    .table th,.table td{padding:10px 8px;border-bottom:1px solid var(--border-color);text-align:left;font-size:14px}
    .table th{color:#9a9a9a;font-weight:600}

    details.settings[open] summary .chev{rotate:180deg}
    summary{list-style:none;cursor:pointer;display:flex;align-items:center;justify-content:space-between}
    summary::-webkit-details-marker{display:none}
    .chev{transition:rotate .2s}

    dialog{background:var(--card);color:var(--text);border:1px solid var(--border-color);border-radius:14px;padding:0;max-width:520px}
    dialog::backdrop{background:rgb(0 0 0 / .5)}
    .modal-h{padding:16px 18px;border-bottom:1px solid var(--border-color);font-weight:700}
    .modal-b{padding:18px}
    .modal-f{padding:14px 18px;border-top:1px solid var(--border-color);display:flex;justify-content:flex-end;gap:10px}

    code.inline{background:#262629;border:1px solid var(--border-color);padding:2px 6px;border-radius:6px}
      /* ===== Telegram connect block (from scratch) ===== */
    #telegram .tg-row{display:grid;grid-template-columns:1fr;gap:var(--gap)}
    @media (max-width:860px){#telegram .tg-row{grid-template-columns:1fr}}
    #telegram .tg-label{display:block;font-size:13px;color:var(--secondary-color);margin-bottom:6px}
    #telegram .tg-widget{padding:12px;border:1px dashed var(--border-color);border-radius:10px;background:#262629}
    #telegram .code-inline{display:flex;flex-direction:column;gap:8px}
    #telegram .code-inline .input{width:160px}
    #telegram .card-h .fa-telegram{font-size:18px}
  /* === 2FA modern tabs & steps === */
    .tabs{display:flex;gap:8px;background:#262629;border:1px solid var(--border-color);border-radius:10px;padding:6px}
    .tab{flex:1;padding:10px 12px;border-radius:8px;background:transparent;border:1px solid transparent;color:#cdcad3;font-weight:600;cursor:pointer}
    .tab:hover{background:#2f2f32}
    .tab.active{background:#fff;color:#000;border-color:#fff}
    .tab i{margin-right:6px}

    .panel{display:none;padding-top:16px}
    .panel.show{display:block}

    /* new stepper (fixed connectors alignment) */
    #twofa .steps{ --connector:clamp(12px, 2.5vw, 24px); counter-reset:step; display:flex; gap:var(--connector); align-items:center; flex-wrap:wrap; padding:4px 0; overflow:visible }
    #twofa .step{ position:relative; display:flex; align-items:center; gap:8px; padding:10px 14px; background:#262629; border:1px solid var(--border-color); border-radius:10px; color:#bfbfbf; white-space:nowrap; flex:1 1 clamp(220px, 24%, 340px); min-width:220px }
    #twofa .step::before{ counter-increment:step; content:counter(step); display:inline-grid; place-items:center; width:22px; height:22px; border-radius:999px; background:#3f3e43; color:#bfbfbf; font-size:12px; font-weight:700 }
    #twofa .step:not(:last-child)::after{ content:""; position:absolute; right:calc(var(--connector)/-2); top:50%; width:var(--connector); height:2px; background:#3f3e43; transform:translateY(-50%); }
    #twofa .step[data-done="true"]{ color:#fff; border-color:#fff }
    #twofa .step[data-done="true"]::before{ background:#fff; color:#000 }
    #twofa .step[data-done="true"]::after{ background:#fff }
    #twofa .step.active{ outline:2px solid #fff; outline-offset:-2px }
    #twofa .steps.wrap .step::after{ display:none }

    /* ===== Mobile optimizations ===== */
    *{-webkit-tap-highlight-color:transparent}
    @media (max-width:720px){
      :root{--gap:12px;--radius:12px}
      .page-title{font-size:22px;margin-bottom:8px}
      .card-h,.card-b,.card-f{padding-left:14px;padding-right:14px}
      .stack{flex-wrap:wrap}
      .cardt-f{display:grid;grid-template-columns:1fr;gap:8px}
      .cardt-f .btn{width:100%}
      .tabs{overflow-x:auto;-webkit-overflow-scrolling:touch;gap:6px;scrollbar-width:none}
      .tabs::-webkit-scrollbar{display:none}
      .tab{flex:0 0 auto}
      .steps{overflow-x:visible;padding-bottom:0;scrollbar-width:none}
      #twofa .steps{ --connector:18px }
      .steps::-webkit-scrollbar{display:none}
      .switch{--h:28px;--w:54px}
      #telegram .tg-row{grid-template-columns:1fr}
      #telegram .code-inline .input,#telegram .tg-widget{width:100%}
    }

    @media (max-width:640px){
      #device-table thead{display:none}
      #device-table tbody,#device-table tr,#device-table td{display:block;width:100%}
      #device-table tr{background:#262629;border:1px solid var(--border-color);border-radius:12px;margin-bottom:10px;padding:12px}
      #device-table td{border:0;padding:6px 0}
      #device-table td:last-child{padding-top:8px}
      #device-table td::before{content:attr(data-label);display:block;font-size:12px;color:var(--muted);margin-bottom:2px}
    }
  /* === overflow & embed safety belts === */
    html,body{overflow-x:hidden}
    .cardt,.cardt-h,.cardt-b,.grid,.row,.stack,section.stack-col,aside.stack-col{min-width:0;}
    .cardt-b{overflow-x:visible}
    img,iframe{max-width:100%;height:auto}
    #telegram .tg-widget iframe{max-width:100%!important;width:100%!important}



.wrapper{
  align-items: flex-start;
}

.left-column{
  position: sticky;
  top: 20px;
  height: fit-content;
}

.right-panel{
  position: sticky;
  top: 20px;
  height: fit-content;
}

.wrapper, body, html{
  overflow: visible;
}

.modal-hint {
  margin-top: 16px;
  padding: 10px 14px;
  font-size: 13px;
  color: #b8bcc5;
  background: rgba(88, 101, 242, 0.1);
  border-left: 3px solid #5865f2;
  border-radius: 4px;
  display: none;
  align-items: center;
  gap: 8px;
}

.modal-hint.show {
  display: flex;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-5px); }
  to { opacity: 1; transform: translateY(0); }
}

  .server-title{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:12px;
    margin:0;
  }
  .server-title__left{
    display:inline-flex;
    align-items:center;
    gap:10px;
    min-width:0;
  }

  .server-delete-btn{
    flex:0 0 auto;
    color: #cdcad3;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    transition: background-color 0.2s, opacity 0.2s, transform 0.2s;
    user-select: none;
    white-space: nowrap;
    background: #2b2a2d;
    font-family: 'Montserrat', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    border: none;
    opacity: .8;
  }

  .server-delete-btn:hover {
    transform: translateY(-1px);
    opacity: 1;
  }

  .server-delete-btn:active {
    transform: translateY(0px);
    opacity: 0.95;
  }
  .server-delete-btn[disabled] {
    opacity: 0.45;
    cursor: not-allowed;
    transform: none;
  }
.server__header-end {
    display: flex;
    align-items: center;
    justify-content: end;
    gap: 20px;
    justify-self: end;
    flex-wrap: wrap;
    font-size: 13px;
}
.server__version {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 13px;
}
.server__version span {
  color: #919191;
}


/* Контейнер уведомления */
.rpay-alert {
    position: relative;
    display: flex;
    align-items: flex-start; /* Чтобы текст не ехал, если он длинный */
    gap: 15px;
    padding: 16px 20px;
    margin-bottom: 20px;
    border-radius: 8px;
    background: #1e2128; /* Темный фон под вашу панель */
    color: #e4e4e7;       /* Светлый текст */
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25); /* Мягкая тень */
    border-left: 4px solid transparent; /* Место под цветную полоску */
    animation: slideIn 0.4s ease-out forwards;
    overflow: hidden;
}

/* Успех */
.rpay-alert--success {
    border-left-color: #10b981; /* Зеленый акцент */
    background: linear-gradient(90deg, rgba(16, 185, 129, 0.05) 0%, #1e2128 100%);
}
.rpay-alert--success .rpay-alert__icon {
    color: #10b981;
}

/* Ошибка */
.rpay-alert--error {
    border-left-color: #ef4444; /* Красный акцент */
    background: linear-gradient(90deg, rgba(239, 68, 68, 0.05) 0%, #1e2128 100%);
}
.rpay-alert--error .rpay-alert__icon {
    color: #ef4444;
}

/* Иконка */
.rpay-alert__icon {
    font-size: 1.2rem;
    padding-top: 2px;
}

/* Текст */
.rpay-alert__content {
    flex: 1;
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Кнопка закрытия */
.rpay-alert__close {
    background: none;
    border: none;
    color: #71717a;
    cursor: pointer;
    font-size: 1.2rem;
    padding: 0;
    margin-left: 10px;
    transition: color 0.2s;
}
.rpay-alert__close:hover {
    color: #fff;
}

/* Анимация появления */
@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Consent checkbox */
.consent{
  margin: 14px 0 18px;
  text-align: left;
}

.consent-checkbox{
  display: flex;
  gap: 12px;
  align-items: flex-start;
  cursor: pointer;
  user-select: none;
}

.consent-checkbox input{
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}

.consent-checkbox .box{
  width: 20px;
  height: 20px;
  border-radius: 7px;
  background: #262629;
  border: 1px solid #3a3a3f;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 20px;
  margin-top: 2px;
  transition: .2s ease;
}

.consent-checkbox .box i{
  font-size: 12px;
  opacity: 0;
  transform: scale(.7);
  transition: .2s ease;
  color: #000;
}

/* checked state */
.consent-checkbox input:checked + .box{
  background: #ffffff;
  border-color: #ffffff;
}
.consent-checkbox input:checked + .box i{
  opacity: 1;
  transform: scale(1);
}

/* focus (keyboard) */
.consent-checkbox input:focus-visible + .box{
  outline: 2px solid rgba(99, 51, 238, .65);
  outline-offset: 3px;
}

.consent-checkbox .text{
  font-size: 12.5px;
  color: #7b7780;
  line-height: 1.35;
}

.consent-checkbox .text a{
  color: #cfcbd6;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.consent-checkbox .text a:hover{
  color: #ffffff;
}

.btn:disabled{
  opacity: .55;
  cursor: not-allowed;
}

.delete-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  z-index: 1000;
  justify-content: center;
  align-items: center;
}
.delete-modal-overlay.active { 
  display: flex; 
}

.delete-modal {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 15px;
  padding: 28px;
  width: 560px;
  max-width: 90%;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}

.delete-modal__title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-color);
  margin-bottom: 10px;
}

.delete-modal__text {
  font-size: 14px;
  color: #7b7780;
  margin-bottom: 14px;
}

.delete-modal__server-name {
  background: rgba(255, 56, 90, 0.08);
  border: 1px solid rgba(255, 56, 90, 0.25);
  border-radius: 10px;
  padding: 14px 16px;
  color: var(--danger);
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 16px;
}

.delete-modal__input {
  width: 100%;
  padding: 12px 14px;
  background: #262629;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  color: var(--text-color);
  font-size: 14px;
  margin-bottom: 20px;
  box-sizing: border-box;
  transition: border-color 0.2s, box-shadow 0.2s;
  font-family: inherit;
}

.delete-modal__input::placeholder {
  color: #7b7780;
}

.delete-modal__input:focus {
  outline: none;
  border-color: rgba(255, 255, 255, 0.18);
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.08);
}

.delete-modal__actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
}

.delete-modal__actions .btn {
  padding: 10px 20px;
  font-size: 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.delete-modal__actions .btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.server-item.deleting {
  animation: fadeOut 0.3s ease forwards;
}

@keyframes fadeOut {
  to { 
    opacity: 0; 
    transform: translateX(-20px); 
  }
}

#rpay-gw-credentials {
    display: contents;
}