@import url('https://fonts.googleapis.com/css2?family=Raleway:wght@400;500;600;700&display=swap');

.kcf-wrapper {
  font-family: 'Raleway', sans-serif;
  display: flex;
  justify-content: center;
  padding: 40px 20px;
}

/* CARD */
.kcf-card {
  background: #ffffff;
  border-radius: 24px;
  width: 100%;
  max-width: 680px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.10), 0 4px 20px rgba(0,0,0,0.06);
  border: 1px solid rgba(0,0,0,0.06);
  overflow: hidden;
}

/* HEADER */
.kcf-header {
  background: linear-gradient(135deg, #6c63ff 0%, #8b5cf6 50%, #a78bfa 100%);
  padding: 36px 40px 32px;
  text-align: center;
}
.kcf-icon { font-size: 42px; margin-bottom: 12px; display: block; }
.kcf-title {
  font-size: 26px !important;
  font-weight: 700 !important;
  color: #ffffff !important;
  margin: 0 0 8px !important;
  padding: 0 !important;
  border: none !important;
  text-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.kcf-subtitle {
  font-size: 15px;
  color: rgba(255,255,255,0.85);
  margin: 0;
  line-height: 1.5;
}

/* BODY */
.kcf-body { padding: 36px 40px 40px; }

/* ROW */
.kcf-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

/* FIELD */
.kcf-field { margin-bottom: 20px; }
.kcf-label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: #374151;
  margin-bottom: 7px;
  letter-spacing: 0.3px;
}
.kcf-req { color: #ef4444; }
.kcf-field-hint {
  font-size: 12px;
  color: #9ca3af;
  margin: -4px 0 8px;
  line-height: 1.5;
}

/* INPUTS */
.kcf-input {
  width: 100% !important;
  padding: 13px 16px !important;
  border: 1.5px solid #e5e7eb !important;
  border-radius: 12px !important;
  font-size: 14px !important;
  color: #1a1a2e !important;
  font-family: 'Raleway', sans-serif !important;
  outline: none !important;
  background: #fafafa !important;
  transition: all 0.2s !important;
  box-sizing: border-box !important;
}
.kcf-input:focus {
  border-color: #6c63ff !important;
  box-shadow: 0 0 0 3px rgba(108,99,255,0.12) !important;
  background: #fff !important;
}
.kcf-input::placeholder { color: #d1d5db; font-size: 13px; }

/* PHONE */
.kcf-phone-wrap {
  display: flex;
  align-items: center;
  border: 1.5px solid #e5e7eb;
  border-radius: 12px;
  background: #fafafa;
  overflow: hidden;
  transition: all 0.2s;
}
.kcf-phone-wrap:focus-within {
  border-color: #6c63ff;
  box-shadow: 0 0 0 3px rgba(108,99,255,0.12);
  background: #fff;
}
.kcf-phone-prefix {
  padding: 13px 12px 13px 16px;
  font-size: 13px;
  font-weight: 600;
  color: #6b7280;
  white-space: nowrap;
  border-right: 1.5px solid #e5e7eb;
  background: #f3f4f6;
}
.kcf-phone-input {
  border: none !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  flex: 1;
}
.kcf-phone-input:focus { box-shadow: none !important; }

/* TEXTAREA */
.kcf-textarea {
  resize: vertical !important;
  min-height: 140px !important;
  line-height: 1.6 !important;
}
.kcf-char-count {
  text-align: right;
  font-size: 12px;
  color: #9ca3af;
  margin-top: 5px;
}

/* CONSENT */
.kcf-consent {
  margin-bottom: 20px;
  font-size: 13px;
  color: #6b7280;
  line-height: 1.5;
}
.kcf-consent input {
  margin-right: 8px;
  accent-color: #6c63ff;
  width: 15px;
  height: 15px;
  vertical-align: middle;
  cursor: pointer;
}

/* ERROR */
.kcf-error {
  background: #fee2e2;
  border: 1px solid #fca5a5;
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 13px;
  color: #991b1b;
  font-weight: 600;
  margin-bottom: 16px;
}

/* SUBMIT BTN */
.kcf-btn {
  width: 100%;
  padding: 16px;
  background: linear-gradient(135deg, #6c63ff, #8b5cf6) !important;
  color: #fff !important;
  border: none !important;
  border-radius: 14px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  font-family: 'Raleway', sans-serif;
  letter-spacing: 0.5px;
  box-shadow: 0 6px 24px rgba(108,99,255,0.4);
  transition: all 0.3s;
  position: relative;
  overflow: hidden;
}
.kcf-btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent 30%, rgba(255,255,255,0.2) 50%, transparent 70%);
  transform: translateX(-100%);
  transition: transform 0.6s;
}
.kcf-btn:hover::after { transform: translateX(100%); }
.kcf-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 32px rgba(108,99,255,0.55); }
.kcf-btn:disabled { opacity: 0.7; cursor: not-allowed; transform: none; }

/* SPINNER */
.kcf-spinner {
  display: inline-block;
  width: 16px; height: 16px;
  border: 2px solid rgba(255,255,255,0.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: kcf-spin 0.7s linear infinite;
  vertical-align: middle;
  margin-right: 6px;
}
@keyframes kcf-spin { to { transform: rotate(360deg); } }

/* ══ SUCCESS POPUP ══════════════════════════ */
.kcf-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 6, 30, 0.75);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(6px);
  animation: kcf-fade-in 0.3s ease;
}

@keyframes kcf-fade-in { from { opacity: 0; } to { opacity: 1; } }

.kcf-popup {
  background: #fff;
  border-radius: 24px;
  padding: 48px 40px 40px;
  max-width: 440px;
  width: 90%;
  text-align: center;
  box-shadow: 0 30px 80px rgba(0,0,0,0.25);
  animation: kcf-slide-up 0.4s cubic-bezier(.34,1.56,.64,1);
  position: relative;
  overflow: hidden;
}

@keyframes kcf-slide-up {
  from { opacity: 0; transform: translateY(40px) scale(0.95); }
  to   { opacity: 1; transform: translateY(0)   scale(1); }
}

/* Popup top gradient bar */
.kcf-popup::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 5px;
  background: linear-gradient(90deg, #6c63ff, #8b5cf6, #a78bfa);
}

/* ANIMATION CIRCLES */
.kcf-popup-anim { position: relative; margin-bottom: 20px; display: inline-block; }
.kcf-popup-icon { font-size: 56px; display: block; position: relative; z-index: 2; animation: kcf-bounce 0.6s 0.3s cubic-bezier(.34,1.56,.64,1) both; }
@keyframes kcf-bounce { from{transform:scale(0) rotate(-10deg)} to{transform:scale(1) rotate(0)} }

.kcf-circle {
  position: absolute;
  border-radius: 50%;
  animation: kcf-ring 1.5s ease-out infinite;
}
.c1 { width: 70px;  height: 70px;  top: 50%; left: 50%; margin: -35px 0 0 -35px; background: rgba(108,99,255,0.15); animation-delay: 0.2s; }
.c2 { width: 95px;  height: 95px;  top: 50%; left: 50%; margin: -47px 0 0 -47px; background: rgba(108,99,255,0.08); animation-delay: 0.5s; }
.c3 { width: 120px; height: 120px; top: 50%; left: 50%; margin: -60px 0 0 -60px; background: rgba(108,99,255,0.04); animation-delay: 0.8s; }
@keyframes kcf-ring {
  0%   { transform: scale(0.8); opacity: 1; }
  100% { transform: scale(1.4); opacity: 0; }
}

.kcf-popup-title {
  font-family: 'Raleway', sans-serif !important;
  font-size: 28px !important;
  font-weight: 700 !important;
  color: #1a1a2e !important;
  margin: 0 0 14px !important;
  border: none !important;
  padding: 0 !important;
}

.kcf-popup-msg {
  font-size: 15px;
  color: #4b5563;
  line-height: 1.8;
  margin-bottom: 20px;
}

.kcf-popup-details {
  background: #f3f4f6;
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 13px;
  color: #6b7280;
  margin-bottom: 24px;
  text-align: left;
  line-height: 1.7;
}

.kcf-popup-btn {
  background: linear-gradient(135deg, #6c63ff, #8b5cf6) !important;
  color: #fff !important;
  border: none !important;
  padding: 14px 40px;
  border-radius: 50px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  font-family: 'Raleway', sans-serif;
  box-shadow: 0 6px 20px rgba(108,99,255,0.4);
  transition: all 0.3s;
}
.kcf-popup-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 28px rgba(108,99,255,0.55); }

/* RESPONSIVE */
@media (max-width: 600px) {
  .kcf-body { padding: 24px 20px 28px; }
  .kcf-header { padding: 28px 20px 24px; }
  .kcf-row { grid-template-columns: 1fr; gap: 0; }
  .kcf-popup { padding: 36px 24px 32px; }
  .kcf-popup-title { font-size: 22px !important; }
}
