@import url('https://fonts.googleapis.com/css2?family=MonteCarlo&display=swap');


/* ============================================================
   CERTIFICATE SECTION STYLES
   Scoped under .cert-section so it won't clash with your site.
   ============================================================ */

.cert-section {
  --cert-navy: #1b2a63;
  --cert-navy-dark: #121d47;
  --cert-gold: #e8ac2e;
  --cert-brown: #7a3b2e;
  --cert-bg: #f7f8fb;
  --cert-card: #ffffff;
  --cert-text: #1f2430;
  --cert-muted: #6b7280;
  --cert-error: #d64545;
  --cert-radius: 16px;

  font-family: 'Poppins', system-ui, -apple-system, sans-serif;
  background: var(--cert-bg);
  padding: 64px 24px;
  color: var(--cert-text);
  box-sizing: border-box;
}

.cert-section *,
.cert-section *::before,
.cert-section *::after {
  box-sizing: border-box;
}

.cert-wrap {
  max-width: 1180px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 380px 1fr;
  gap: 32px;
  align-items: start;
}

@media (max-width: 860px) {
  .cert-wrap {
    grid-template-columns: 1fr;
  }
}

/* ---------- Form card ---------- */
.cert-form-card {
  background: var(--cert-card);
  border-radius: var(--cert-radius);
  padding: 32px 28px;
  box-shadow: 0 10px 30px rgba(18, 29, 71, 0.08);
  border: 1px solid rgba(18, 29, 71, 0.06);
  width: 480px !important;
}

.cert-form-title {
  font-size: 24px;
  font-weight: 400;
  line-height: 1.2;
  color: var(--cert-navy-dark);
  margin: 0 0 6px;
}

.cert-form-sub {
  font-size: 14px;
  color:#444444;
  margin: 0 0 24px;
  line-height: 1.5;
}

.cert-field {
  margin-bottom: 0px;
  display: flex;
  flex-direction: column;
 
}

.cert-field label {
  margin-bottom: 2px;
  font-size: 13px;
  font-weight: 600;
  color: var(--cert-text);
}

.cert-field input[type="text"],
.cert-field input[type="email"], 
.cert-field input[type="tel"]{
  font-family: inherit;
  font-size: 15px;
  padding: 12px 14px;
  border: 1.5px solid #dde1ea;
  border-radius: 10px;
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
  background: #fbfbfd;
}

.cert-field input[type="text"]:focus,
.cert-field input[type="email"]:focus, 
.cert-field input[type="tel"]:focus {
  border-color: var(--cert-navy);
  box-shadow: 0 0 0 3px rgba(27, 42, 99, 0.12);
  background: #fff;
}

.cert-field input.invalid {
  border-color: var(--cert-error);
}

.cert-checkbox-field {
  flex-direction: row;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 4px;
}

.cert-checkbox-field input[type="checkbox"] {
  margin-top: 3px;
  width: 17px;
  height: 17px;
  accent-color: var(--cert-navy);
  flex-shrink: 0;
}

.cert-checkbox-field label {
  font-size: 13px;
  font-weight: 400;
  color: var(--cert-muted);
  line-height: 1.45;
}

.cert-error {
  display: block;
  min-height: 16px;
  font-size: 12px;
  color: var(--cert-error);
  margin-bottom: 6px;
}

.cert-submit-btn {
  width: 100%;
  margin-top: 8px;
  padding: 14px 18px;
  border: none;
  border-radius: 10px;
  background: #0081c6;
  color: #fff;
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: transform 0.12s ease, box-shadow 0.12s ease, opacity 0.12s ease;
  box-shadow: 0 8px 18px rgba(27, 42, 99, 0.25);
}

.cert-submit-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 22px rgba(27, 42, 99, 0.3);
}

.cert-submit-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
}

.btn-spinner {
  width: 15px;
  height: 15px;
  border: 2px solid rgba(255, 255, 255, 0.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: cert-spin 0.7s linear infinite;
}

@keyframes cert-spin {
  to { transform: rotate(360deg); }
}

.cert-status {
  margin: 12px 0 0;
  font-size: 13px;
  min-height: 18px;
}

.cert-status.success { color: #1a8a4a; }
.cert-status.error { color: var(--cert-error); }

.cert-download-btn {
  width: 100%;
  max-width: min(100%, calc((55vh - 220px) * 0.707));
  margin: 16px auto 0;
  padding: 14px 18px;
  border: none;
  border-radius: 10px;
  background:#0081c6;
  color: #fff;
  font-family: 'Poppins', inherit;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: transform 0.12s ease, box-shadow 0.12s ease, opacity 0.12s ease;
  box-shadow: 0 8px 18px rgba(20, 107, 57, 0.25);
}

.cert-download-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 22px rgba(20, 107, 57, 0.3);
}

.cert-download-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
}

.cert-download-btn[hidden] {
  display: none;
}




/* ---------- Preview card ---------- */
.cert-preview-card {
  /* background: var(--cert-card);
  border-radius: var(--cert-radius);
  box-shadow: 0 10px 30px rgba(18, 29, 71, 0.08);
  border: 1px solid rgba(18, 29, 71, 0.06); */
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.cert-preview-frame {
  position: relative;
  width: 450px;
  height: 625px;
  aspect-ratio: 1414 / 2000;
  margin: 0 auto;

  border-radius: 6px;
  overflow: hidden;
  background: #fff;
  border: 6px solid #fff;
  outline: 1px solid #e7c98a;
  outline-offset: -1px;
  box-shadow: 0 12px 32px rgba(18, 29, 71, 0.16);
}

.cert-preview-frame canvas {
  width: 100%;
  height: 100%;
  display: block;
}

@media (max-width: 860px) {
  .cert-preview-frame {
    width: 100%;
    max-width: 450px;
    height: auto;
    aspect-ratio: 1414 / 2000;
  }
}
.cert-preview-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #a7adba;
  font-size: 14px;
  line-height: 1.5;
  background: url('/assets/images/usagrowth.png') no-repeat center center;
  background-size: contain;
  transition: opacity 0.25s ease;
}

.cert-preview-placeholder.hidden {
  opacity: 0;
  pointer-events: none;
}



.disclaimer-modal {
  display: none;
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.5);
  overflow-y: auto; /* allows modal itself to scroll on small screens */
}

.disclaimer-content {
  background: #fff;
  width: 90%;
  max-width: 600px;
  max-height: 80vh; /* limits popup height to 80% of screen */
  margin: 6% auto;
  padding: 25px;
  border-radius: 10px;
  font-size: 14px;
  position: relative;
  line-height: 1.6;
  overflow-y: auto; /* scroll inside content */
  box-sizing: border-box;
}

.disclaimer-content p{
  margin-bottom: 5px;
}

.close-disclaimer {
  position: sticky;
  float: right;
  right: 20px;
  top: 10px;
  font-size: 28px;
  cursor: pointer;
  z-index: 10;
  background: #fff;
}

.head-dis{
  font-weight: 400;
  text-align: center;
  font-size: 18px;
}