:root {
  --bg: radial-gradient(1200px 600px at 10% 10%, #f0f4ff 0%, #ffffff 40%, #fefefe 100%);
  --calc-ar: 5 / 7;
}

html, body {
  height: 100%;
}

body {
  background: var(--bg);
}

html body {
  padding-top: 0;
}

.calc-wrap {
  aspect-ratio: var(--calc-ar);
  width: min(100vw, calc(100vh * var(--calc-ar)));
  height: auto;
}

.card, .card-body {
  height: 100%;
}

.card-body {
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

.password-display-container {
  display: flex;
  gap: 10px;
  align-items: stretch;
}

.password-output {
  flex: 1;
  padding: 16px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border-radius: 0.5rem;
  font-family: 'Courier New', monospace;
  font-size: 1.1rem;
  word-break: break-all;
  min-height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

#copy-btn {
  padding: 0 20px;
  border-radius: 0.5rem;
  transition: all 0.3s ease;
}

.strength-container {
  padding: 12px;
  background: #f8f9fa;
  border-radius: 0.5rem;
}

.strength-label {
  font-weight: 600;
  font-size: 0.9rem;
}

.strength-text {
  font-weight: 700;
  font-size: 0.9rem;
}

.progress {
  border-radius: 10px;
  overflow: hidden;
}

.progress-bar {
  transition: width 0.5s ease, background-color 0.5s ease;
}

.form-container {
  flex: 1;
  overflow-y: auto;
}

.form-label {
  font-weight: 600;
  color: #495057;
  margin-bottom: 0.5rem;
}

.form-check {
  padding: 0.4rem 0;
}

.form-check-label {
  font-size: 0.95rem;
}

.batch-results {
  max-height: 200px;
  overflow-y: auto;
}

.batch-password {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 10px;
  margin-bottom: 8px;
  background: #f8f9fa;
  border-radius: 0.375rem;
  border: 1px solid #dee2e6;
}

.batch-password .password-text {
  flex: 1;
  font-family: 'Courier New', monospace;
  font-size: 0.9rem;
  word-break: break-all;
}

@media (max-width: 575.98px) {
  .calc-wrap {
    width: 100vw;
    height: 100vh;
    aspect-ratio: auto;
  }
  
  .password-output {
    font-size: 0.9rem;
    padding: 12px;
    min-height: 50px;
  }
  
  #copy-btn {
    padding: 0 15px;
  }
}

@media (min-width: 576px) and (max-width: 991.98px) {
  :root { 
    --calc-ar: 6 / 8; 
  }
}

@media (min-width: 992px) {
  :root { 
    --calc-ar: 5 / 7; 
  }
}
