/* XKeypad Sample Page Styles */
.xkeypad-sample-container {
  min-height: 100vh;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', sans-serif;
}

.sample-card {
  background: white;
  border-radius: 20px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
  padding: 40px;
  width: 100%;
  max-width: 500px;
  animation: fadeInUp 0.5s ease;
}

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

.sample-card h1 {
  color: #2d3748;
  font-size: 28px;
  font-weight: 700;
  margin: 0 0 12px 0;
  text-align: center;
}

.description {
  color: #718096;
  text-align: center;
  margin-bottom: 30px;
  font-size: 15px;
  line-height: 1.6;
}

.password-form {
  margin-bottom: 30px;
}

.form-group {
  margin-bottom: 25px;
}

.form-group label {
  display: block;
  color: #4a5568;
  font-weight: 600;
  margin-bottom: 10px;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.input-wrapper {
  position: relative;
}

.password-input {
  width: 100%;
  padding: 14px 45px 14px 16px;
  border: 2px solid #e2e8f0;
  border-radius: 12px;
  font-size: 16px;
  transition: all 0.3s ease;
  background: #f7fafc;
  cursor: pointer;
  box-sizing: border-box;
}

.password-input:hover {
  border-color: #cbd5e0;
  background: #fff;
}

.password-input:focus {
  outline: none;
  border-color: #667eea;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.input-icon {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 20px;
  pointer-events: none;
}

.help-text {
  display: block;
  color: #a0aec0;
  font-size: 13px;
  margin-top: 8px;
  font-style: italic;
}

.button-group {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 12px;
}

.submit-btn {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border: none;
  padding: 14px 24px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(102, 126, 234, 0.3);
}

.submit-btn:active {
  transform: translateY(0);
}

.reset-btn {
  background: #f7fafc;
  color: #4a5568;
  border: 2px solid #e2e8f0;
  padding: 14px 24px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.reset-btn:hover {
  background: #e2e8f0;
  border-color: #cbd5e0;
}

/* Result Section */
.result-section {
  background: #f0f7ff;
  border: 1px solid #bee3f8;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 30px;
  animation: slideIn 0.3s ease;
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.result-section h3 {
  color: #2b6cb6;
  font-size: 16px;
  font-weight: 600;
  margin: 0 0 15px 0;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.result-content {
  background: white;
  border-radius: 8px;
  padding: 15px;
}

.result-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid #e2e8f0;
}

.result-item:last-child {
  border-bottom: none;
}

.result-item .label {
  color: #718096;
  font-weight: 500;
  font-size: 14px;
}

.result-item .value {
  color: #2d3748;
  font-family: 'Courier New', monospace;
  font-size: 14px;
  font-weight: 600;
}

.result-item .value.encrypted {
  color: #667eea;
  word-break: break-all;
  text-align: right;
  max-width: 300px;
  font-size: 12px;
}

/* Info Section */
.info-section {
  background: #faf5ff;
  border: 1px solid #e9d8fd;
  border-radius: 12px;
  padding: 20px;
}

.info-section h3 {
  color: #553c9a;
  font-size: 16px;
  font-weight: 600;
  margin: 0 0 15px 0;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.info-section ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.info-section li {
  color: #44337a;
  padding: 8px 0;
  border-bottom: 1px solid #e9d8fd;
  font-size: 14px;
  display: flex;
  align-items: center;
}

.info-section li:last-child {
  border-bottom: none;
}

/* Loading State */
.loading {
  text-align: center;
  padding: 40px;
  background: white;
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.loading p {
  color: #4a5568;
  font-size: 18px;
  margin: 0;
  animation: pulse 1.5s ease infinite;
}

@keyframes pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

/* Responsive Design */
@media (max-width: 600px) {
  .sample-card {
    padding: 30px 20px;
  }

  .sample-card h1 {
    font-size: 24px;
  }

  .button-group {
    grid-template-columns: 1fr;
  }

  .password-input {
    font-size: 16px; /* iOS zoom 방지 */
  }
}

/* 키패드가 열릴 때 스크롤 방지 */
body.keypad-open {
  overflow: hidden;
  position: fixed;
  width: 100%;
}