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

body {
  min-height: 100vh;
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #0f172a 100%);
  display: flex;
  justify-content: center;
  align-items: center;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen,
    Ubuntu, Cantarell, sans-serif;
  overflow-y: auto;
  overflow-x: hidden;
  position: relative;
  padding: 40px 20px;
}

body::before {
  content: "";
  position: absolute;
  width: 400px;
  height: 400px;
  background: radial-gradient(
    circle,
    rgba(59, 130, 246, 0.2) 0%,
    transparent 70%
  );
  border-radius: 50%;
  top: -100px;
  left: -100px;
  animation: float 20s ease-in-out infinite;
}

body::after {
  content: "";
  position: absolute;
  width: 300px;
  height: 300px;
  background: radial-gradient(
    circle,
    rgba(139, 92, 246, 0.15) 0%,
    transparent 70%
  );
  border-radius: 50%;
  bottom: -50px;
  right: -50px;
  animation: float 25s ease-in-out infinite reverse;
}

@keyframes float {
  0%,
  100% {
    transform: translate(0, 0);
  }
  50% {
    transform: translate(30px, 30px);
  }
}

.container {
  position: relative;
  z-index: 10;
  background: rgba(15, 23, 42, 0.7);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(59, 130, 246, 0.2);
  border-radius: 24px;
  padding: 50px 40px;
  width: 90%;
  max-width: 500px;
  animation: slideInUp 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

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

h1 {
  text-align: center;
  color: #e2e8f0;
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 10px;
  letter-spacing: -0.5px;
}

.subtitle {
  text-align: center;
  color: #cbd5e1;
  font-size: 14px;
  margin-bottom: 40px;
  font-weight: 500;
}

.password-display {
  background: linear-gradient(
    135deg,
    rgba(30, 41, 59, 0.8) 0%,
    rgba(15, 23, 42, 0.6) 100%
  );
  border: 1.5px solid rgba(59, 130, 246, 0.3);
  border-radius: 16px;
  padding: 24px;
  text-align: center;
  margin-bottom: 35px;
  font-size: 20px;
  font-weight: 600;
  letter-spacing: 1px;
  word-break: break-all;
  color: #e2e8f0;
  min-height: 70px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "Courier New", monospace;
  position: relative;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.password-display::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.1),
    transparent
  );
  animation: shimmer 2s infinite;
}

@keyframes shimmer {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(100%);
  }
}

.password-display:hover {
  border-color: rgba(59, 130, 246, 0.6);
  box-shadow: 0 0 20px rgba(59, 130, 246, 0.2);
}

.options {
  margin-bottom: 35px;
  background: rgba(30, 41, 59, 0.5);
  border: 1px solid rgba(59, 130, 246, 0.15);
  border-radius: 16px;
  padding: 24px;
  backdrop-filter: blur(10px);
}

.option {
  display: flex;
  align-items: center;
  margin-bottom: 16px;
  padding: 12px 14px;
  background: rgba(51, 65, 85, 0.3);
  border: 1px solid rgba(100, 116, 139, 0.2);
  border-radius: 12px;
  transition: all 0.3s ease;
  cursor: pointer;
}

.option:last-child {
  margin-bottom: 0;
}

.option:hover {
  background: rgba(51, 65, 85, 0.6);
  border-color: rgba(59, 130, 246, 0.4);
  transform: translateX(4px);
}

input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 24px;
  height: 24px;
  cursor: pointer;
  margin-right: 14px;
  border-radius: 8px;
  background: rgba(71, 85, 105, 0.5);
  border: 2px solid rgba(100, 116, 139, 0.6);
  transition: all 0.3s ease;
  position: relative;
  flex-shrink: 0;
}

input[type="checkbox"]:hover {
  border-color: #3b82f6;
  background: rgba(71, 85, 105, 0.8);
}

input[type="checkbox"]:checked {
  background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 100%);
  border-color: #3b82f6;
  box-shadow: 0 0 15px rgba(59, 130, 246, 0.5),
    inset 0 0 10px rgba(59, 130, 246, 0.3);
}

input[type="checkbox"]:checked::after {
  content: "✓";
  position: absolute;
  color: white;
  font-size: 16px;
  font-weight: bold;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  align-items: center;
  justify-content: center;
}

label {
  flex: 1;
  cursor: pointer;
  font-weight: 500;
  color: #cbd5e1;
  user-select: none;
}

.length-control {
  background: rgba(51, 65, 85, 0.3);
  border: 1px solid rgba(100, 116, 139, 0.2);
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 35px;
  backdrop-filter: blur(10px);
}

.length-label-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.length-label-row label {
  margin: 0;
  color: #cbd5e1;
  font-weight: 600;
}

.length-display {
  background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 100%);
  color: white;
  padding: 6px 14px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 14px;
  min-width: 45px;
  text-align: center;
}

input[type="range"] {
  width: 100%;
  height: 7px;
  border-radius: 4px;
  background: linear-gradient(
    to right,
    rgba(59, 130, 246, 0.3),
    rgba(139, 92, 246, 0.3)
  );
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 100%);
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(59, 130, 246, 0.5);
  transition: all 0.2s ease;
}

input[type="range"]::-webkit-slider-thumb:hover {
  transform: scale(1.2);
  box-shadow: 0 6px 20px rgba(59, 130, 246, 0.7);
}

input[type="range"]::-moz-range-thumb {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 100%);
  cursor: pointer;
  border: none;
  box-shadow: 0 4px 15px rgba(59, 130, 246, 0.5);
  transition: all 0.2s ease;
}

.copy-btn {
  width: 100%;
  padding: 16px;
  background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 100%);
  color: white;
  border: none;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(59, 130, 246, 0.4);
}

.copy-btn::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.2),
    transparent
  );
  animation: btnShimmer 2s infinite;
}

@keyframes btnShimmer {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(100%);
  }
}

.copy-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(59, 130, 246, 0.6);
}

.copy-btn:active {
  transform: translateY(-1px);
}

.copy-feedback {
  text-align: center;
  color: #10b981;
  font-size: 14px;
  margin-top: 12px;
  opacity: 0;
  transition: opacity 0.3s ease;
  font-weight: 600;
}

.copy-feedback.show {
  opacity: 1;
}
