* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

body {
  background-color: rgb(255, 255, 255);
  display: flex;
  justify-content: center;
  padding: 20px 16px;
  min-height: 100vh;
}

.container {
  width: 100%;
  max-width: 420px;
  text-align: center;
}

.logo {
  font-size: 32px;
  color: #0064e1;
  font-weight: 800;
  letter-spacing: -1.2px;
  margin-bottom: 24px;
  display: inline-block;
}

.logo span {
  font-weight: 400;
}

.tagline {
  font-size: 17px;
  line-height: 1.3;
  color: #333;
  margin-bottom: 24px;
}

.partners-grid {
  margin-bottom: 28px;
  opacity: 0.9;
}

.partners-grid img {
  max-width: 100%;
  height: auto;
}

.form-box {
  margin-bottom: 32px;
}

.input-container {
  text-align: left;
  margin-bottom: 16px;
}

.input-container label {
  display: block;
  font-size: 14px;
  color: #666;
  margin-bottom: 6px;
  font-weight: 500;
}

.input-container input {
  width: 100%;
  height: 52px;
  padding: 0 14px;
  font-size: 16px;
  border: 1px solid #ccc;
  border-radius: 8px;
  outline: none;
  background: #fff;
}

.input-container input:focus {
  border-color: #0064e1;
}

.input-container input.invalid {
  border-color: #e42313;
}

.error-text {
  color: #e42313;
  font-size: 12px;
  margin-top: 4px;
  display: none;
}

.btn-main {
  width: 100%;
  height: 50px;
  background-color: #0064e1;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  text-transform: none;
}

.btn-main:hover {
  background-color: #0056c1;
}

.btn-main:disabled {
  background-color: #ccc;
  cursor: not-allowed;
  opacity: 0.7;
}

.loading-spinner {
  width: 20px;
  height: 20px;
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  border-top-color: #fff;
  animation: spin 0.8s linear infinite;
  display: none;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.benefits-card {
  background: #fff;
  border-radius: 16px;
  padding: 24px;
  text-align: left;
  margin-bottom: 32px;
  border: 1px solid #eee;
}

.benefits-card h2 {
  font-size: 16px;
  margin-bottom: 16px;
  color: #1a1a1a;
  font-weight: 700;
}

.benefit-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 12px;
}

.svg-check {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  margin-top: 2px;
}

.benefit-item p {
  font-size: 14px;
  color: #444;
  line-height: 1.4;
}

.legal-footer {
  padding: 16px;
  font-size: 11px;
  color: #888;
  line-height: 1.5;
  text-align: center;
}

.legal-footer a {
  color: #666;
  text-decoration: none;
  font-weight: 600;
}

.quiz-container {
  text-align: left;
}

.progress-bar {
  height: 6px;
  background: #e0e0e0;
  border-radius: 3px;
  margin-bottom: 20px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: #0064e1;
  width: 0%;
  transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.option-item {
  padding: 18px 16px;
  border: 1px solid #e0e0e0;
  border-radius: 12px;
  margin-bottom: 12px;
  cursor: pointer;
  font-size: 15px;
  font-weight: 500;
  color: #333;
  transition: all 0.2s;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.option-item:active {
  background-color: #f0f7ff;
  border-color: #0064e1;
}

.option-item::after {
  content: '→';
  color: #0064e1;
  opacity: 0;
  transform: translateX(-10px);
  transition: all 0.2s;
}

.facial-area-container {
  position: relative;
  width: 280px;
  height: 360px;
  margin: 0 auto 24px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.facial-area {
  position: relative;
  width: 260px;
  height: 340px;
  border-radius: 50%;
  overflow: hidden;
  padding: 6px;
  background: conic-gradient(#28a745 var(--progress, 0%), #e0e0e0 0);
  z-index: 2;
  transform: translateZ(0);
  transition: box-shadow 0.3s;
}

.facial-area.validating {
  box-shadow: 0 0 25px rgba(40, 167, 69, 0.3);
}

.video-wrapper {
  width: 100%;
  height: 100%;
  position: relative;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  overflow: hidden;
}

#video-stream {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scaleX(-1);
  opacity: 0;
  transition: opacity 0.5s;
}

.video-wrapper.video-active #video-stream {
  opacity: 1;
}

.output_canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 20;
  transform: scaleX(-1);
  border-radius: 50%;
}

.face-id-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 120px;
  height: 120px;
  z-index: 5;
  transition: opacity 0.3s;
  opacity: 0.6;
}

.video-wrapper.video-active .face-id-icon {
  opacity: 0;
}

.scan-line {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: #28a745;
  box-shadow: 0 0 20px #28a745, 0 0 40px #28a745;
  animation: scanning 1.5s ease-in-out infinite;
  opacity: 0;
  z-index: 10;
}

.facial-area.validating .scan-line {
  opacity: 1;
}

@keyframes scanning {
  0% {
    top: 0%;
    opacity: 0;
  }

  15% {
    opacity: 1;
  }

  85% {
    opacity: 1;
  }

  100% {
    top: 100%;
    opacity: 0;
  }
}

.facial-instruction {
  font-size: 15px;
  color: #555;
  margin-bottom: 24px;
  line-height: 1.5;
  max-width: 280px;
  margin-left: auto;
  margin-right: auto;
  min-height: 42px;
  font-weight: 500;
  transition: color 0.2s;
}

.feedback-default {
  color: #555;
}

.feedback-warn {
  color: #e47c13;
  font-weight: 700;
}

.feedback-success {
  color: #28a745;
  font-weight: 700;
}

.receipt-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  animation: fadeIn 0.5s ease;
  padding-bottom: 20px;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.success-icon-wrapper {
  width: 54px;
  height: 54px;
  background: #e6f6ec;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  margin-top: 10px;
}

.success-icon-wrapper svg {
  width: 26px;
  height: 26px;
}

.receipt-title {
  font-size: 22px;
  font-weight: 700;
  color: #2c3e50;
  margin-bottom: 6px;
}

.receipt-subtitle {
  font-size: 14px;
  color: #555;
  text-align: center;
  line-height: 1.4;
  margin-bottom: 24px;
  max-width: 320px;
  font-weight: 500;
}

.receipt-card {
  background: #ffffff;
  border-radius: 12px;
  width: 100%;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03);
  margin-bottom: 24px;
  border: 1px solid #eef0f2;
  overflow: hidden;
}

.receipt-card-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 16px 20px;
  color: #28a745;
  font-weight: 600;
  font-size: 14px;
  background: #f8fafb;
  border-bottom: 1px solid #eef0f2;
}

.receipt-details {
  padding: 20px;
}

.receipt-row-main {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  font-size: 15px;
  color: #555;
}

.receipt-row-main .text-green {
  color: #1e7e34;
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.5px;
}

.receipt-row-sub {
  display: flex;
  justify-content: space-between;
  margin-bottom: 12px;
  font-size: 14px;
  color: #666;
}

.receipt-row-sub:last-child {
  margin-bottom: 0;
}

.receipt-row-sub strong {
  color: #333;
  font-weight: 600;
}

.insurance-alert {
  background: #fdf5d3;
  border-radius: 12px;
  padding: 20px;
  width: 100%;
  text-align: left;
  margin-bottom: 28px;
}

.insurance-alert p {
  font-size: 13px;
  color: #5d4a1f;
  line-height: 1.5;
  margin-bottom: 16px;
}

.insurance-alert strong {
  color: #1e7e34;
}

.checkbox-block {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
}

.checkbox-block input {
  display: none;
}

.custom-check {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid #28a745;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.custom-check svg {
  display: none;
}

.checkbox-block input:checked+.custom-check {
  background: #28a745;
}

.checkbox-block input:checked+.custom-check svg {
  display: block;
}

.checkbox-block span {
  font-size: 14px;
  color: #333;
  font-weight: 600;
}

#btn-withdraw {
  background-color: #1255c4;
  height: 52px;
  border-radius: 10px;
  font-size: 16px;
  letter-spacing: 0.2px;
}

#btn-withdraw:hover {
  background-color: #0e44a0;
}

#btn-withdraw:disabled {
  background-color: #9ab4e1;
  opacity: 1;
}

@media (max-width: 480px) {
  body {
    padding-top: 20px;
  }

  .logo {
    font-size: 28px;
    margin-bottom: 20px;
  }

  .facial-area-container {
    width: 240px;
    height: 300px;
  }

  .facial-area {
    width: 220px;
    height: 280px;
  }

  .receipt-row-main .text-green {
    font-size: 22px;
  }
}

.skeleton-anim {
  background: linear-gradient(90deg, #f0f0f0 25%, #ffffff 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
}

@keyframes skeleton-loading {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}