/* Com'Claire Ressources — Public form styles */
:root {
  --ccr-blue:       #1A56C4;
  --ccr-blue-dark:  #0D2248;
  --ccr-blue-light: #E8F0FD;
  --ccr-blue-mid:   #3B8BEB;
  --ccr-text:       #1A1A2E;
  --ccr-grey:       #6B7280;
  --ccr-bg:         #F8FAFC;
  --ccr-border:     #E2E8F0;
  --ccr-green:      #16A34A;
  --ccr-red:        #DC2626;
  --ccr-radius:     12px;
}

.ccr-wrap {
  max-width: 640px;
  margin: 0 auto;
  border-radius: var(--ccr-radius);
  overflow: hidden;
  box-shadow: 0 4px 32px rgba(26,86,196,.10);
  border: 1px solid var(--ccr-border);
  font-family: -apple-system, 'Segoe UI', Arial, sans-serif;
}

/* ── Header ── */
.ccr-header {
  background: linear-gradient(135deg, var(--ccr-blue-dark) 0%, var(--ccr-blue) 100%);
  padding: 28px 32px 22px;
  position: relative;
  overflow: hidden;
}
.ccr-header::after {
  content: '';
  position: absolute;
  right: -40px; top: -40px;
  width: 180px; height: 180px;
  border-radius: 50%;
  background: rgba(255,255,255,.05);
  pointer-events: none;
}

.ccr-badge {
  display: inline-block;
  background: rgba(96,207,255,.22);
  color: #93C5FD;
  font-size: 11px; font-weight: 700;
  letter-spacing: 1.5px; text-transform: uppercase;
  padding: 3px 12px; border-radius: 20px;
  margin-bottom: 10px;
}

.ccr-title {
  color: #fff !important;
  font-size: 19px !important;
  line-height: 1.4 !important;
  margin: 0 0 8px !important;
  font-weight: 700;
  position: relative; z-index: 1;
}

.ccr-description {
  color: rgba(255,255,255,.75);
  font-size: 13px; line-height: 1.6;
  margin: 0; position: relative; z-index: 1;
}

.ccr-meta-tags {
  display: flex; flex-wrap: wrap; gap: 8px;
  margin-top: 12px; position: relative; z-index: 1;
}
.ccr-meta-tags span {
  background: rgba(255,255,255,.12);
  color: rgba(255,255,255,.8);
  font-size: 11px; padding: 3px 10px;
  border-radius: 10px;
}

/* ── Body ── */
.ccr-body { background: #fff; padding: 28px 32px; }

/* "Ce que vous obtenez" box */
.ccr-wyg {
  background: var(--ccr-blue-light);
  border-left: 4px solid var(--ccr-blue);
  border-radius: 0 8px 8px 0;
  padding: 16px 20px;
  margin-bottom: 22px;
}
.ccr-wyg-title {
  font-size: 12px !important;
  font-weight: 700; color: var(--ccr-blue) !important;
  letter-spacing: 1px; text-transform: uppercase;
  margin: 0 0 10px !important;
}
.ccr-wyg ul {
  margin: 0; padding: 0; list-style: none;
}
.ccr-wyg li {
  font-size: 13px; color: #374151;
  padding: 4px 0 4px 20px;
  position: relative; line-height: 1.5;
}
.ccr-wyg li::before {
  content: '✓';
  position: absolute; left: 0;
  color: var(--ccr-blue); font-weight: 700;
}

/* Preview */
.ccr-preview { margin-bottom: 22px; text-align: center; }
.ccr-preview img {
  max-width: 100%; border-radius: 8px;
  border: 1px solid var(--ccr-border);
  box-shadow: 0 2px 12px rgba(0,0,0,.08);
}
.ccr-preview-label {
  font-size: 11px; color: #9CA3AF;
  margin: 6px 0 0; text-align: center;
}

/* ── Form section ── */
.ccr-form-section {
  background: var(--ccr-blue);
  border-radius: 10px;
  padding: 24px 26px;
}
.ccr-form-section h3 {
  color: #fff !important;
  font-size: 16px !important;
  margin: 0 0 4px !important;
}
.ccr-form-section > p {
  color: rgba(255,255,255,.7);
  font-size: 13px; margin: 0 0 18px;
}

/* ── Fields ── */
.ccr-row { display: flex; gap: 12px; }
.ccr-row .ccr-field { flex: 1; }
.ccr-field { margin-bottom: 12px; }
.ccr-field label {
  display: block; font-size: 12px;
  color: rgba(255,255,255,.75);
  margin-bottom: 5px; font-weight: 500;
}
.ccr-field label span { color: #FCA5A5; }

.ccr-field input[type="text"],
.ccr-field input[type="email"] {
  width: 100%;
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.25);
  border-radius: 7px;
  padding: 10px 14px;
  color: #fff; font-size: 14px;
  transition: border-color .2s, box-shadow .2s;
  box-sizing: border-box;
}
.ccr-field input::placeholder { color: rgba(255,255,255,.4); }
.ccr-field input:focus {
  outline: none;
  border-color: rgba(255,255,255,.6);
  box-shadow: 0 0 0 3px rgba(255,255,255,.1);
}
.ccr-field input.ccr-invalid {
  border-color: #FCA5A5;
  box-shadow: 0 0 0 3px rgba(252,165,165,.15);
}

/* GDPR */
.ccr-gdpr {
  margin-bottom: 14px;
}
.ccr-gdpr label {
  display: flex; gap: 10px; align-items: flex-start;
  font-size: 12px; color: rgba(255,255,255,.6);
  cursor: pointer; line-height: 1.5;
}
.ccr-gdpr input[type="checkbox"] {
  flex-shrink: 0; margin-top: 2px; accent-color: #fff;
}
.ccr-gdpr a { color: rgba(255,255,255,.5); }

/* Message */
.ccr-msg {
  display: none;
  padding: 10px 14px;
  border-radius: 7px;
  font-size: 13px;
  margin-bottom: 12px;
  font-weight: 500;
}
.ccr-msg.ccr-success {
  display: block;
  background: rgba(22,163,74,.2);
  color: #BBF7D0;
  border: 1px solid rgba(22,163,74,.4);
}
.ccr-msg.ccr-error {
  display: block;
  background: rgba(220,38,38,.2);
  color: #FCA5A5;
  border: 1px solid rgba(220,38,38,.4);
}

/* Button */
.ccr-btn {
  width: 100%;
  background: #fff;
  color: var(--ccr-blue);
  border: none; border-radius: 8px;
  padding: 13px 20px;
  font-size: 15px; font-weight: 700;
  cursor: pointer;
  transition: background .2s, transform .1s;
  display: flex; align-items: center; justify-content: center; gap: 8px;
}
.ccr-btn:hover:not(:disabled) { background: #EFF6FF; }
.ccr-btn:active               { transform: scale(.98); }
.ccr-btn:disabled             { opacity: .7; cursor: not-allowed; }

/* Spinner */
.ccr-spinner {
  width: 18px; height: 18px;
  animation: ccr-spin 1s linear infinite;
  vertical-align: middle;
}
@keyframes ccr-spin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }

/* ── Success state ── */
.ccr-wrap.ccr-done .ccr-form-section { display: none; }
.ccr-success-box {
  background: linear-gradient(135deg,#052010,#0A3020);
  border: 1px solid #22C55E;
  border-radius: 10px;
  padding: 28px;
  text-align: center;
}
.ccr-success-box .ccr-check {
  font-size: 48px; display: block; margin-bottom: 12px;
}
.ccr-success-box h4 {
  color: #4ADE80 !important;
  font-size: 16px !important;
  margin: 0 0 8px !important;
}
.ccr-success-box p {
  color: rgba(255,255,255,.7);
  font-size: 13px; margin: 0;
}

/* Responsive */
@media (max-width: 520px) {
  .ccr-header, .ccr-body { padding: 20px 18px; }
  .ccr-row { flex-direction: column; gap: 0; }
  .ccr-form-section { padding: 18px; }
  .ccr-btn { font-size: 14px; }
}
