/* CodeVN Theme Stylesheet for iPA Signer */

body {
  font-size: 18px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  min-height: 100vh;
}

body.bg-dark {
  background-color: #343a40 !important;
}

.container {
  max-width: 880px;
  margin: 0 auto;
}

/* Header & Logo */
.logo {
  max-width: 170px;
  height: auto;
  transition: transform 0.2s;
}

.logo:hover {
  transform: scale(1.03);
}

.nav a:hover {
  color: #fff !important;
  background-color: #6c757d;
  border-radius: 0.25rem !important;
  text-decoration: none;
}

.nav a {
  font-size: 15px;
  transition: all 0.2s;
}

/* Jumbotron */
.jumbotron {
  background-color: #e9ecef;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  border-radius: 8px;
}

.jumbotron h1 {
  font-weight: 700;
  color: #212529;
}

.jumbotron ul {
  padding-left: 20px;
  font-size: 16px;
}

.jumbotron p, .jumbotron li {
  color: #333;
  line-height: 1.6;
}

/* Form Inputs */
input[type=checkbox], input[type=radio] {
  box-sizing: border-box;
  padding: 0;
  width: 22px;
  height: 22px;
}

.form-check-input[type="radio"] {
  width: 20px;
  height: 20px;
  background-color: #fff;
  border: 1px solid #adb5bd;
  border-radius: 50%;
  margin-right: 6px;
  vertical-align: middle;
  cursor: pointer;
}

label.form-label {
  display: inline-block;
  vertical-align: middle;
  margin-bottom: 0;
  padding-left: 2px;
  cursor: pointer;
  font-weight: 500;
  color: #333;
  font-size: 15px;
}

/* IPA Dashed Drop Box (Image 1) */
.ipa-dashed-box {
  border: 1.5px dashed #28a745;
  border-radius: 4px;
  background-color: rgba(40, 167, 69, 0.03);
  padding: 18px 12px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  user-select: none;
}

.ipa-dashed-box:hover {
  background-color: rgba(40, 167, 69, 0.08);
}

.ipa-dashed-box.active-drag {
  border-color: #17a2b8 !important;
  background-color: rgba(23, 162, 184, 0.1) !important;
}

.ipa-dashed-box .file-icon {
  color: #28a745;
  display: flex;
  justify-content: center;
  align-items: center;
  line-height: 1;
}

.ipa-dashed-box .ipa-filename {
  font-weight: 700;
  font-size: 15px;
  color: #212529;
  margin-top: 5px;
  margin-bottom: 2px;
  word-break: break-all;
}

.ipa-dashed-box .ipa-filesize {
  font-size: 13.5px;
  color: #6c757d;
  margin-bottom: 3px;
}

.ipa-dashed-box .ipa-hint {
  font-size: 13px;
  color: #6c757d;
}

/* Custom File Picker Input Group (Image 1 & 2) */
.custom-file-picker {
  height: 38px;
  border: 1px solid #28a745;
  border-radius: 4px;
  background-color: #fff;
  cursor: pointer;
  overflow: hidden;
  width: 100%;
  transition: border-color 0.2s;
}

.custom-file-picker .picker-display {
  color: #495057;
  font-size: 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  user-select: none;
}

.custom-file-picker .picker-btn {
  border: none;
  border-left: 1px solid #28a745;
  border-radius: 0;
  background-color: #fff;
  color: #495057;
  font-size: 14px;
  padding: 0 16px;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.15s;
}

.custom-file-picker:hover .picker-btn {
  background-color: #f1f3f5;
}

/* Remove Embedded Box (Image 1) */
.remove-embedded-box {
  height: 38px;
  border: 1px solid #ced4da;
  border-radius: 4px;
  background-color: #fff;
  padding: 0 12px;
  cursor: pointer;
  user-select: none;
  font-size: 14px;
  color: #495057;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0 !important;
  width: 100%;
}

.remove-embedded-box input[type="checkbox"] {
  width: 17px;
  height: 17px;
  cursor: pointer;
  accent-color: #007bff;
  margin: 0;
}

/* Input with Icon on Right (Image 1) */
.input-with-icon {
  position: relative;
  width: 100%;
}

.input-with-icon .form-control {
  height: 38px;
  padding-right: 36px;
  font-size: 14px;
  border-radius: 4px;
}

.input-with-icon .input-icon {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.form-control.field-valid {
  border-color: #28a745 !important;
  background-color: #fff;
}

.form-control.field-valid:focus {
  border-color: #28a745 !important;
  box-shadow: 0 0 0 0.2rem rgba(40, 167, 69, 0.25) !important;
}

.form-control.field-invalid {
  border-color: #dc3545 !important;
  background-color: #fff;
}

.form-control.field-invalid:focus {
  border-color: #dc3545 !important;
  box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25) !important;
}

/* Upload Button */
.btn_upload {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.5px;
  transition: all 0.2s;
  background-color: #17a2b8;
  border-color: #17a2b8;
  box-shadow: 0 4px 10px rgba(23, 162, 184, 0.25);
  border-radius: 4px;
}

.btn_upload:hover {
  background-color: #138496;
  border-color: #117a8b;
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(23, 162, 184, 0.35);
}

/* Progress bar */
.progress {
  border-radius: 6px;
  overflow: hidden;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.2);
}

.progress-bar {
  transition: width 0.3s ease;
}

/* Validation Styling */
.form-control.is-valid {
  border-color: #28a745 !important;
  background-color: #f8fff9;
}

.form-control.is-invalid {
  border-color: #dc3545 !important;
}

/* Download button animation */
#downloadButton {
  font-weight: 700;
  transition: all 0.25s ease;
  font-size: 18px;
}

#downloadButton:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 18px rgba(40, 167, 69, 0.4) !important;
}


/* Result box styles */
.result-card {
  background: #ffffff;
  border-radius: 8px;
  padding: 24px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
  margin-top: 20px;
}

.app-icon-img {
  width: 80px;
  height: 80px;
  border-radius: 18px;
  object-fit: cover;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
}

.qr-wrapper {
  background: #ffffff;
  padding: 10px;
  border-radius: 10px;
  display: inline-block;
  border: 1px solid #dee2e6;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.qr-wrapper img {
  width: 160px;
  height: 160px;
  display: block;
}

footer a {
  transition: color 0.2s;
}

footer a:hover {
  color: #adb5bd !important;
  text-decoration: underline;
}

/* ==========================================================
   Language Switcher (Google translateHtml Engine)
   ========================================================== */
.lang-switcher-wrap {
  display: inline-flex !important;
  align-items: center !important;
}

.lang-switcher {
  display: inline-flex !important;
  flex-direction: row !important;
  align-items: center !important;
  gap: 8px !important;
  background: transparent !important;
  padding: 0 !important;
  margin: 0 !important;
  border: none !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

.lang-flag,
.lang-btn {
  width: 22px !important;
  height: 22px !important;
  min-width: 22px !important;
  max-width: 22px !important;
  border-radius: 50% !important;
  padding: 0 !important;
  margin: 0 !important;
  border: none !important;
  background: transparent !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  transition: transform 0.15s ease, opacity 0.15s ease;
  outline: none !important;
  box-shadow: none !important;
  opacity: 0.45;
  line-height: 0 !important;
  overflow: visible !important;
}

.lang-flag:hover,
.lang-btn:hover {
  opacity: 0.9 !important;
  transform: scale(1.12);
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
}

.lang-flag.active,
.lang-flag.active-lang,
.lang-btn.active,
.lang-btn.active-lang {
  opacity: 1 !important;
  transform: scale(1.06);
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
}

.lang-flag-img {
  width: 22px !important;
  height: 22px !important;
  border-radius: 50% !important;
  object-fit: cover !important;
  display: block !important;
  pointer-events: none;
  border: none !important;
  box-shadow: none !important;
  filter: none !important;
}


/* ==========================================================
   Clean Google Translate Toolbar & Popups
   ========================================================== */
.goog-te-banner-frame,
.goog-te-banner-frame.skiptranslate,
iframe.goog-te-banner-frame {
  display: none !important;
  visibility: hidden !important;
  height: 0 !important;
}

body {
  top: 0px !important;
  position: static !important;
}

#google_translate_element,
.goog-te-gadget {
  display: none !important;
}

.goog-tooltip,
.goog-tooltip:hover,
#goog-gt-tt,
.goog-te-balloon-frame {
  display: none !important;
}

.goog-text-highlight {
  background-color: transparent !important;
  border: none !important;
  box-shadow: none !important;
}

font {
  background-color: transparent !important;
  box-shadow: none !important;
}


