/* Хедер профиля */
.profile-header-wrapper {
  margin-bottom: 24px;
}

.profile-header {
  display: flex;
  align-items: flex-start;
  flex-direction: column;
  gap: 8px;
}

.profile-title {
  font-family: 'Inter', ui-sans-serif, system-ui;
  font-size: 30px;
  font-weight: 700;
  color: #ffffff;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 16px;
}

.profile-title i {
  font-size: 36px;
  background: linear-gradient(135deg, #0572FF 0%, #034499 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.profile-subtitle {
  font-family: 'Inter', ui-sans-serif, system-ui;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.65);
  margin: 0;
}

/* Основной контейнер */
.profile-main-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  width: 100%;
  align-items: stretch;
}

/* Карточки */
.profile-card {
  background: rgba(255, 255, 255, 0.03);
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  overflow: hidden;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.profile-card-header {
  padding: 10px 15px 0;
}

.profile-card-title {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 1.5rem;
  line-height: 1;
  font-weight: 600;
  color: #ffffff;
  margin: 0;
  font-family: 'Jost', sans-serif;
}

.profile-card-title i {
  font-size: 18px;
  color: rgba(255, 255, 255, 0.7);
}

.profile-card-body {
  padding: 15px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* Левая колонка */
.profile-left-column {
  display: flex;
  flex-direction: column;
  gap: 20px;
  height: 100%;
}

/* Правая колонка */
.profile-right-column {
  display: flex;
  flex-direction: column;
  gap: 20px;
  height: 100%;
}

.profile-info {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.profile-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Статистика */
.stats-grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
  flex: 1;
}

.stat-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 5px 10px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all 0.2s ease;
  width: 100%;
  flex-direction: row;
}

.stat-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.stat-icon i {
  font-size: 35px;
  color: #0572FF;
}

.stat-content {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}

.stat-label {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
  font-weight: 400;
}

.stat-value {
  font-size: 16px;
  color: #ffffff;
  font-weight: 600;
}

.stat-status {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
  font-weight: 400;
  margin-top: 2px;
}


.stat-card-subscription.status-active .stat-icon i {
  color: #28a745;
}


.stat-card-subscription.status-trial .stat-icon i {
  color: #ffc107;
}


.stat-card-subscription.status-expired .stat-icon i {
  color: #dc3545;
}

.stat-card-subscription.status-inactive .stat-icon i {
  color: #6c757d;
}

/* Действия формы */
.profile-form-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: auto;
  padding-top: 15px;
}

/* Действия */
.profile-actions-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.action-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 10px 20px;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: "Inter", ui-sans-serif, system-ui;
  text-decoration: none;
  width: 100%;
}

.action-btn:hover {
  background: linear-gradient(135deg, #2cb94d 0%, #1e7e34 100%);
}

.action-btn i {
  font-size: 16px;
}

.action-btn-primary {
  background: linear-gradient(135deg, #28a745 0%, #1e7e34 100%);
  color: #ffffff;
}

.action-btn-secondary {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.action-btn-danger {
  background: linear-gradient(135deg, #ff054f 0%, #99030e 100%);
  color: #ffffff;
}

.action-btn-danger:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(255, 5, 79, 0.3);
}

.action-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
}

/* Скрытие элементов по умолчанию */
.profile-form-error {
  display: none;
}

/* Модальные окна профиля */
.profile-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 10001;
  display: none;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.profile-subtitle{
  font-family: 'Inter', ui-sans-serif, system-ui ;
  font-size: 15px;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.5;
}

.profile-modal.show {
  display: flex;
  pointer-events: all;
}

.profile-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}

.profile-modal-content {
  position: relative;
  background: #121212;
  border-radius: 12px;
  width: 90%;
  max-width: 500px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
  z-index: 1;
}

.profile-modal-header {
  padding: 15px 20px;
  border-bottom: 1px solid var(--border-color, rgba(255, 255, 255, 0.1));
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.profile-modal-header h3 {
  margin: 0;
  font-size: 20px;
  font-weight: 600;
  color: var(--text-primary, #ffffff);
}

.profile-modal-close {
  background: none;
  border: none;
  color: var(--text-secondary, rgba(255, 255, 255, 0.6));
  font-size: 20px;
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  transition: all 0.2s;
}

.profile-modal-close:hover {
  background: var(--bg-tertiary, rgba(255, 255, 255, 0.1));
  color: var(--text-primary, #ffffff);
}

.profile-modal-body {
  padding: 15px 24px 15px 24px;
  overflow-y: auto;
  flex: 1;
}

.profile-modal-footer {
  padding: 16px 24px;
  border-top: 1px solid var(--border-color, rgba(255, 255, 255, 0.1));
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

.profile-modal-footer .profile-btn {
  padding: 10px 20px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #0572FF 0%, #034499 100%);
    color: #ffffff;
    font-family: "Inter", ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, Noto Sans, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
}

/* Уведомления профиля */
.profile-notification-container {
  position: fixed;
  top: 30px;
  right: 20px;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 400px;
}

.profile-notification {
  padding: 16px 20px;
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  gap: 12px;
  animation: profileSlideIn 0.3s ease-out;
  min-width: 300px;
}

@keyframes profileSlideIn {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

.profile-notification-success {
  background: #28a745;
  color: white;
}

.profile-notification-error {
  background: #dc3545;
  color: white;
}

.profile-notification-info {
  background: #17a2b8;
  color: white;
}

.profile-notification-icon {
  font-size: 20px;
}

.profile-notification-message {
  flex: 1;
  font-size: 14px;
}

.profile-notification-close {
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.8);
  cursor: pointer;
  font-size: 18px;
  padding: 0;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  transition: all 0.2s;
}

.profile-notification-close:hover {
  background: rgba(255, 255, 255, 0.2);
  color: white;
}

/* Модальная форма пароля */
#password-form {
  gap: 10px;
  display: flex;
  flex-direction: column;
}

#password-old, #password-new, #password-confirm {
  width: 100%;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: #ffffff;
  font-size: 11px;
  transition: all 0.3s ease;
}

#password-old:focus, #password-new:focus, #password-confirm:focus {
  outline: none;
  border-color: rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.08);
}



.group-row-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.group-row {
  display: flex;
  flex-direction: row;
  gap: 15px;
  padding: 10px 0;
}

/* Стили для форм */
.form-group {
  display: flex;
  flex-direction: column;
  margin: 0;
}

.form-group label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.7);
  margin: 0 0 0 5px;
}

.form-group label i {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.5);
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"],
.form-group input[type="url"] {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  color: #ffffff;
  font-size: 14px;
  transition: all 0.2s;
  box-sizing: border-box;
}

.form-group input[type="text"]:focus,
.form-group input[type="email"]:focus,
.form-group input[type="password"]:focus,
.form-group input[type="url"]:focus {
  outline: none;
  border-color: rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.08);
}

.form-group input[readonly] {
  background: rgba(255, 255, 255, 0.03);
  color: rgba(255, 255, 255, 0.5);
  cursor: not-allowed;
}

.form-hint {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 2px 0 0 2px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
}

.form-hint i {
  font-size: 11px;
}

.form-hint-readonly {
  color: rgba(255, 255, 255, 0.45);
}


/* Форма профиля */
form#profile-form {
  display: flex;
  gap: 13px;
  flex-direction: column;
  flex: 1;
  justify-content: center;
}

/* Подписка */
.subscription-info {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.subscription-status-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  width: fit-content;
  border: 1px solid;
}

.subscription-status-badge i {
  font-size: 18px;
}

.status-active {
  background: rgba(40, 167, 69, 0.15);
  color: #28a745;
  border-color: rgba(40, 167, 69, 0.3);
}

.status-trial {
  background: rgba(255, 193, 7, 0.15);
  color: #ffc107;
  border-color: rgba(255, 193, 7, 0.3);
}

.status-expired {
  background: rgba(220, 53, 69, 0.15);
  color: #dc3545;
  border-color: rgba(220, 53, 69, 0.3);
}

.subscription-details {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.subscription-detail-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.subscription-detail-item:last-child {
  border-bottom: none;
}

.detail-label {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.6);
  font-weight: 400;
}

.detail-value {
  font-size: 14px;
  color: #ffffff;
  font-weight: 600;
}

.detail-value.highlight {
  color: #0572FF;
  font-size: 16px;
}

.subscription-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: auto;
}

.subscription-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12.5px 20px;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: "Inter", ui-sans-serif, system-ui;
  text-decoration: none;
  width: 100%;
}

.subscription-btn i {
  font-size: 14px;
}

.btn-activate {
  background: linear-gradient(135deg, #0572FF 0%, #034499 100%);
  color: #ffffff;
}

.plan-cta:hover:not(:disabled) i {
  transform: translateX(4px);
}

.btn-renew {
  background: linear-gradient(135deg, #28a745 0%, #1e7e34 100%);
  color: #ffffff;
}

.btn-renew:hover {
  background: linear-gradient(135deg, #2cb94d 0%, #1e7e34 100%);
}

/* Кнопка выхода (фиксированная) */
.logout-btn-fixed {
  position: fixed;
  bottom: 25px;
  right: 25px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 10px 75px;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: "Inter", ui-sans-serif, system-ui;
  text-decoration: none;
  background: linear-gradient(135deg, #ff054f 0%, #99030e 100%);
  color: #ffffff;
  z-index: 100;
}

.logout-btn-fixed i {
  font-size: 16px;
}

.logout-btn-fixed:hover {
  background: linear-gradient(135deg, #fa2367 0%, #b30410 100%);
}

.logout-btn-fixed:active {
  transform: translateY(-1px);
}

/* Кнопка поддержки */
.support-btn-wrapper {
  display: flex;
  width: 100%;
}

.support-btn {
  bottom: 25px;
  right: 260px;
  position: fixed;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 9.5px 20px;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: "Inter", ui-sans-serif, system-ui;
  text-decoration: none;
  /* width: 100%; */
  background: linear-gradient(135deg, #0572FF 0%, #034499 100%);
  color: #ffffff;
}

.support-btn i {
  font-size: 16px;
}

.support-btn:hover {
  background: linear-gradient(135deg, #0d7fff 0%, #0444aa 100%);
}

.support-image-preview {
  position: absolute;
    bottom: calc(100%);
    left: 50%;
    transform: translateX(-50%) scale(0);
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
    z-index: 1000;
    width: 150px;
    height: auto;
    padding: 10px;
    overflow: hidden;
    background: transparent;
    /* border-radius: 8px; */
    /* border: 1px solid rgba(255, 255, 255, 0.1); */
}

.support-image-preview img {
  width: 100%;
  height: auto;
  display: block;
}

.support-btn:hover .support-image-preview {
  transform: translateX(-50%) scale(1);
  opacity: 1;
  pointer-events: auto;
}

@media (max-width: 930px) {
  .form-group label {
    font-size: 10px;
  }

  .form-group input[type="text"], .form-group input[type="email"], .form-group input[type="password"], .form-group input[type="url"]{
    font-size: 10px;
  }

  .profile-card-title {
    font-size: 18px;
  }

  form#profile-form {
    gap: 17px;
  }

  .profile-form-actions {
    padding-top: 15px;
  }

  .action-btn {
    padding: 8px 10px;
    font-size: 10px;
  }

  .subscription-btn {
    padding: 7px 10px;
    font-size: 10px;
  }

  /* #last-login-stat-card {
    display: none;
  } */

  .stat-label {
    font-size: 11px;
  }

  .stat-value {
    font-size: 14px;
  }

  .profile-form-actions {
    flex-direction: column;
  }

  .profile-subtitle {
    font-size: 10px;
  }
}