:root {
  --bg: linear-gradient(135deg, #667eea, #764ba2);
  --text: #ffffff;
  --box-bg: rgba(255, 255, 255, 0.1);
  --box-blur: 20px;
  --accent: #00e6e6;
  --btn-hover: #00cccc;
}

body.dark {
  --bg: linear-gradient(135deg, #121212, #1f1f1f);
  --text: #ffffff;
  --box-bg: rgba(255, 255, 255, 0.05);
  --accent: #00bcd4;
  --btn-hover: #009eaa;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Segoe UI', sans-serif;
}

body {
  background: var(--bg);
  background-attachment: fixed;
  background-size: cover;
  color: var(--text);
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 2rem;
  min-height: 100vh;
  transition: background 0.5s ease;
}

.container {
  backdrop-filter: blur(var(--box-blur));
  background: var(--box-bg);
  border-radius: 1.5rem;
  box-shadow: 0 8px 32px rgba(0,0,0,0.25);
  padding: 2rem;
  max-width: 400px;
  width: 100%;
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.15);
  transition: all 0.4s ease;
}

h1 {
  text-align: center;
  margin-bottom: 1.5rem;
  font-size: 1.8rem;
  font-weight: 600;
  letter-spacing: 1px;
}

.output-box {
  display: flex;
  margin-bottom: 1rem;
  border-radius: 0.5rem;
  overflow: hidden;
}

.output-box input {
  flex: 1;
  padding: 0.8rem 1rem;
  font-size: 1rem;
  border: none;
  outline: none;
  background: rgba(255,255,255,0.15);
  color: var(--text);
}

.output-box button {
  padding: 0.8rem 1rem;
  border: none;
  background: var(--accent);
  color: #000;
  font-weight: bold;
  font-size: 1.1rem;
  cursor: pointer;
  transition: background 0.3s ease;
}

.output-box button:hover {
  background: var(--btn-hover);
}

.controls {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  margin-bottom: 1.5rem;
}

.controls label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.95rem;
}

.controls input[type="range"] {
  width: 100%;
  accent-color: var(--accent);
}

button#generateBtn {
  background: var(--accent);
  color: #000;
  border: none;
  padding: 0.9rem;
  font-size: 1rem;
  font-weight: bold;
  cursor: pointer;
  border-radius: 0.5rem;
  margin-bottom: 1rem;
  transition: background 0.3s ease;
  display: block; 
  text-align: center;
  margin: 1rem auto;
}

button#generateBtn:hover {
  background: var(--btn-hover);
}

#strengthIndicator {
  margin-bottom: 1rem;
  font-weight: 500;
  font-size: 0.95rem;
  
}
#strengthIndicator {
  background-color: #667eea;
  margin: 1rem auto;
  font-weight: 500;
  font-size: 0.95rem;
  text-align: center;
  display: block;
  width: fit-content;
  padding: 0.4rem 1rem;
  border-radius: 0.5rem;
  background: rgba(210, 214, 210, 0.08);
  backdrop-filter: blur(5px);
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}


#strengthText {
  font-weight: bold;
}

#toggleTheme {
  background: transparent;
  border: 2px solid var(--accent);
  color: var(--accent);
  padding: 0.6rem;
  border-radius: 0.5rem;
  cursor: pointer;
  font-weight: bold;
  width: 100%;
  transition: all 0.3s ease;
}

#toggleTheme:hover {
  background: var(--accent);
  color: #000;
}

@media (max-width: 500px) {
  .container {
    padding: 1.2rem;
  }
}
