.profile-card {
    background-color: var(--secondary-black);
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border-color);
}

.photo-wrapper {
  position: relative;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-shrink: 0;
  border: 4px solid var(--primary-white);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
  background:
    radial-gradient(circle at top, rgba(255, 255, 255, 0.12), transparent 58%),
    linear-gradient(160deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02));
}

.profile-photo {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border: 0;
  box-shadow: none;
}

.photo-placeholder {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 18px;
  text-align: center;
  color: var(--primary-white);
  background:
    radial-gradient(circle at top, rgba(255, 255, 255, 0.12), transparent 56%),
    linear-gradient(180deg, rgba(17, 24, 39, 0.92), rgba(17, 24, 39, 0.72));
}

.photo-placeholder__icon {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.82);
  font-size: 22px;
}

.photo-placeholder__spinner {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 3px solid rgba(255, 255, 255, 0.16);
  border-top-color: var(--accent-color);
  animation: photo-loading-spin 0.9s linear infinite;
}

.photo-placeholder__text {
  max-width: 132px;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
  color: var(--accent-white);
}

.photo-placeholder__vpn {
  max-width: 136px;
  font-size: 11px;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.72);
}

.photo-wrapper.has-photo .photo-placeholder {
  display: none;
}

.photo-wrapper.is-empty .photo-placeholder__text,
.photo-wrapper.has-error .photo-placeholder__text {
  color: var(--primary-white);
}

:root[data-theme="light"] .photo-wrapper {
  border-color: rgba(18, 25, 38, 0.08);
  box-shadow: 0 8px 22px rgba(18, 25, 38, 0.14);
  background:
    radial-gradient(circle at top, rgba(255, 255, 255, 0.96), rgba(238, 243, 251, 0.92)),
    linear-gradient(180deg, rgba(243, 247, 255, 1), rgba(233, 239, 249, 0.96));
}

:root[data-theme="light"] .photo-placeholder {
  color: #162033;
  background:
    radial-gradient(circle at top, rgba(255, 255, 255, 0.98), rgba(240, 245, 252, 0.94)),
    linear-gradient(180deg, rgba(250, 252, 255, 0.98), rgba(238, 244, 252, 0.96));
}

:root[data-theme="light"] .photo-placeholder__icon {
  background: rgba(22, 32, 51, 0.08);
  color: rgba(22, 32, 51, 0.72);
}

:root[data-theme="light"] .photo-placeholder__text {
  color: rgba(22, 32, 51, 0.82);
}

:root[data-theme="light"] .photo-placeholder__vpn {
  color: rgba(22, 32, 51, 0.58);
}

.notification-layer {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.notification {
  min-width: min(88vw, 260px);
  max-width: min(92vw, 420px);
  padding: 14px 18px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: var(--secondary-black);
  color: var(--primary-white);
  text-align: center;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.35;
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.36);
  transform: translateY(14px) scale(0.96);
  opacity: 0;
  filter: blur(4px);
  will-change: opacity, transform, filter;
  transition: opacity 0.34s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.34s cubic-bezier(0.22, 1, 0.36, 1),
              filter 0.34s cubic-bezier(0.22, 1, 0.36, 1);
}

.notification.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
  filter: blur(0);
}

.notification.success {
  border-color: rgba(76, 175, 80, 0.65);
  box-shadow: 0 16px 34px rgba(76, 175, 80, 0.2);
}

.notification.error {
  border-color: rgba(255, 59, 48, 0.66);
  box-shadow: 0 16px 34px rgba(255, 59, 48, 0.23);
}

.photo-upload {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
}

.photo-upload__input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
  border: 0;
  padding: 0;
  margin: 0;
}

.photo-upload__trigger {
  flex: 1;
  min-height: 48px;
  border: 1px dashed rgba(255, 255, 255, 0.34);
  border-radius: 12px;
  background: linear-gradient(155deg, rgba(255, 255, 255, 0.09) 0%, rgba(255, 255, 255, 0.03) 100%);
  color: var(--primary-white);
  padding: 10px 14px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.photo-upload__trigger:hover {
  transform: translateY(-1px);
  border-color: rgba(255, 255, 255, 0.52);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.25);
}

.photo-upload__trigger:focus-visible {
  outline: none;
  border-color: rgba(255, 255, 255, 0.64);
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.14);
}

.photo-upload__trigger-icon {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.14);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
}

.photo-upload__trigger-text {
  font-size: 14px;
  font-weight: 600;
}

.photo-upload__preview {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  border: 1px solid var(--border-color);
  background: var(--accent-black);
  color: var(--primary-white);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease, background-color 0.2s ease;
}

.photo-upload__preview:hover {
  transform: translateY(-1px);
  border-color: rgba(255, 255, 255, 0.46);
  background: rgba(255, 255, 255, 0.08);
}

.photo-upload__preview:focus-visible {
  outline: none;
  border-color: rgba(255, 255, 255, 0.64);
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.12);
}

.photo-upload__preview:disabled {
  opacity: 0.5;
  cursor: default;
  transform: none;
}

:root[data-theme="light"] .photo-upload__trigger {
  border-color: rgba(18, 25, 38, 0.24);
  background: linear-gradient(155deg, rgba(255, 255, 255, 0.98) 0%, rgba(241, 245, 252, 0.98) 100%);
}

:root[data-theme="light"] .photo-upload__trigger:hover {
  border-color: rgba(18, 25, 38, 0.4);
}

:root[data-theme="light"] .photo-upload__trigger:focus-visible {
  border-color: rgba(18, 25, 38, 0.58);
  box-shadow: 0 0 0 3px rgba(18, 25, 38, 0.14);
}

:root[data-theme="light"] .photo-upload__trigger-icon {
  background: rgba(18, 25, 38, 0.08);
}

:root[data-theme="light"] .photo-upload__preview {
  border-color: rgba(18, 25, 38, 0.24);
  background: #f3f7ff;
}

:root[data-theme="light"] .photo-upload__preview:hover {
  border-color: rgba(18, 25, 38, 0.38);
  background: #eaf0fb;
}

.form-hint {
  margin-top: 8px;
  font-size: 12px;
  color: var(--accent-white);
  opacity: 0.85;
}

.photo-cropper-modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.photo-cropper-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}

.photo-cropper-modal__content {
  position: relative;
  z-index: 1;
  width: min(92vw, 420px);
  background: var(--secondary-black);
  border-radius: 14px;
  border: 1px solid var(--border-color);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
}

.photo-cropper-modal__viewport {
  --cropper-hole: 70%;
  position: relative;
  width: min(78vw, 320px);
  height: min(78vw, 320px);
  margin: 0 auto;
  border-radius: 12px;
  background: #000;
  overflow: hidden;
  cursor: grab;
  touch-action: none;
}

.photo-cropper-modal__viewport.is-dragging {
  cursor: grabbing;
}

.photo-cropper-modal__viewport img {
  position: absolute;
  top: 0;
  left: 0;
  user-select: none;
  -webkit-user-drag: none;
}

.photo-cropper-modal__overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(
    circle at center,
    rgba(0, 0, 0, 0) 0 calc(var(--cropper-hole) / 2),
    rgba(0, 0, 0, 0.6) calc(var(--cropper-hole) / 2 + 1px)
  );
}

.photo-cropper-modal__controls {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.photo-cropper-modal__label {
  font-size: 13px;
  color: var(--accent-white);
}

.photo-cropper-modal__controls input[type="range"] {
  width: 100%;
}

.photo-cropper-modal__actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.photo-preview-modal {
  position: fixed;
  inset: 0;
  z-index: 1060;
  display: flex;
  align-items: center;
  justify-content: center;
}

.photo-preview-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.62);
}

.photo-preview-modal__content {
  position: relative;
  z-index: 1;
  width: min(92vw, 560px);
  max-height: 86vh;
  padding: 14px;
  border-radius: 14px;
  border: 1px solid var(--border-color);
  background: var(--secondary-black);
  box-shadow: 0 22px 40px rgba(0, 0, 0, 0.45);
}

.photo-preview-modal__content img {
  width: 100%;
  max-height: calc(86vh - 28px);
  display: block;
  border-radius: 10px;
  object-fit: contain;
  background: #000;
}

.photo-preview-modal__close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(255, 255, 255, 0.34);
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.52);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.photo-preview-modal__close:hover {
  background: rgba(0, 0, 0, 0.72);
}

.photo-loading-overlay {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1100;
  background: rgba(0, 0, 0, 0.55);
}

.photo-loading-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 20px 24px;
  background: var(--secondary-black);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  color: var(--primary-white);
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.4);
}

.photo-loading-spinner {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 3px solid rgba(255, 255, 255, 0.2);
  border-top-color: var(--accent-color);
  animation: photo-loading-spin 0.9s linear infinite;
}

.photo-loading-text {
  font-size: 14px;
  font-weight: 600;
  color: var(--accent-white);
}

@keyframes photo-loading-spin {
  to {
    transform: rotate(360deg);
  }
}

.stat-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.stat-number {
  font-size: 28px;
  font-weight: 700;
  line-height: 1;
}

.stat-number.stat-placeholder,
.stat-value.stat-placeholder {
  color: var(--accent-white);
  opacity: 0.45;
}

.stat-unit {
  font-size: 14px;
  opacity: 0.7;
}

.stat-label {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  opacity: 0.6;
}

.player-name {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 5px;
    color: var(--primary-white);
}

.edit-profile-header {
    margin-bottom: 20px;
    text-align: center;
}

.edit-profile-header h2 {
    color: var(--primary-white);
    font-size: 1.5rem;
    margin: 0;
}

.form-row {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
}

.form-group.half {
    flex: 1;
}

.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

@media (max-width: 576px) {
  .photo-upload__trigger {
    padding: 10px 12px;
  }

  .photo-upload__trigger-text {
    font-size: 13px;
  }

  .photo-upload__preview {
    width: 42px;
    height: 42px;
  }
}

.hidden {
    display: none !important;
}
