/**
 * CV Builder Stylesheet — Redesigned
 * Bangladeshi ATS-Friendly CV Standards
 * Font: Arial | Margins: 0.5in
 */

/* ── Layout ── */
.cvb-wrapper,
.cv-builder-wrap {
  min-height: calc(100vh - 80px);
  background: #f8fafc;
  padding: 2rem 0 5rem;
}

.cvb-container,
.cv-builder-wrap .container {
  max-width: 880px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* ── Hero ── */
.cvb-hero-banner {
  text-align: center;
  padding: 1rem 1rem 1.5rem;
  margin-bottom: 1.25rem;
  background: transparent;
  border: none;
  box-shadow: none;
}

.cvb-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  background: #f5f3ff;
  border: 1px solid #ddd6fe;
  color: #7c3aed;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 0.85rem;
}

.cvb-hero-title {
  font-size: 1.85rem;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 0.35rem;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.cvb-hero-sub {
  font-size: 0.95rem;
  color: #64748b;
  margin: 0 0 1.35rem;
  line-height: 1.5;
  max-width: 680px;
  margin-left: auto;
  margin-right: auto;
}

/* ── Hero Buttons ── */
.cvb-hero-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

.cvb-hero-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0.55rem 1.2rem;
  border-radius: 12px;
  font-size: 0.85rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  border: 1.5px solid transparent;
  transition: all 0.2s ease;
  text-decoration: none;
  box-shadow: 0 2px 6px rgba(0,0,0,0.03);
}

.cvb-hero-btn-sample {
  background: #ffffff;
  color: #7c3aed;
  border-color: #ddd6fe;
}
.cvb-hero-btn-sample:hover {
  background: #f5f3ff;
  border-color: #a78bfa;
  transform: translateY(-1px);
}

.cvb-hero-btn-reset {
  background: #ffffff;
  color: #e11d48;
  border-color: #fecdd3;
}
.cvb-hero-btn-reset:hover {
  background: #fff1f2;
  border-color: #fda4af;
  transform: translateY(-1px);
}

.cvb-hero-btn-preview {
  background: #7c3aed;
  color: #ffffff !important;
  border-color: #6d28d9;
  box-shadow: 0 4px 14px rgba(124, 58, 237, 0.25);
}
.cvb-hero-btn-preview:hover {
  background: #6d28d9;
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(124, 58, 237, 0.35);
}

/* ── Status Panel ── */
.cvb-status-panel {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 1rem 1.25rem;
  margin-bottom: 1.35rem;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.02);
}

.cvb-status-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.cvb-strength-info {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.88rem;
  font-weight: 600;
  color: #334155;
}

.cvb-strength-percent {
  color: #7c3aed;
  font-weight: 800;
}

.cvb-strength-count {
  font-size: 0.8rem;
  color: #94a3b8;
}

.cvb-autosave-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 11px;
  border-radius: 999px;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  color: #166534;
  font-size: 0.75rem;
  font-weight: 700;
}

.cvb-autosave-badge.saving {
  background: #fefce8;
  border-color: #fef08a;
  color: #854d0e;
}

.cvb-progress-bar-wrap {
  width: 100%;
  height: 6px;
  background: #e2e8f0;
  border-radius: 999px;
  overflow: hidden;
  margin-top: 10px;
}

.cvb-progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #7c3aed, #10b981);
  border-radius: 999px;
  transition: width 0.4s ease;
}

/* ── Objective Suggestions ── */
.cvb-objective-suggestions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  padding: 0.45rem 0.65rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
}
.cvb-obj-chip {
  font-size: 0.75rem !important;
  font-weight: 600 !important;
  transition: all 0.15s ease;
  cursor: pointer;
}
.cvb-obj-chip:hover {
  background: #f5f3ff !important;
  border-color: #a78bfa !important;
  color: #7c3aed !important;
}

/* ── Form Cards ── */
.cvb-form-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  margin-bottom: 1rem;
  overflow: hidden;
  transition: all 0.2s ease;
  scroll-margin-top: 100px;
}

.cvb-form-card:hover {
  border-color: #cbd5e1;
}

.cvb-form-card.is-active {
  border-color: #a78bfa;
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.08);
}

.cvb-form-header {
  padding: 0.9rem 1.15rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  user-select: none;
  transition: background 0.15s ease;
}

.cvb-form-header:hover {
  background: #f8fafc;
}

.cvb-form-header-left {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 0;
}

.cvb-form-header-icon {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: #f5f3ff;
  color: #7c3aed;
  display: grid;
  place-items: center;
  font-size: 0.9rem;
  flex-shrink: 0;
}

.cvb-form-card.is-active .cvb-form-header-icon {
  background: #7c3aed;
  color: #ffffff;
}

.cvb-form-header h3 {
  font-size: 0.95rem;
  font-weight: 700;
  color: #1e293b;
  margin: 0;
  line-height: 1.3;
}

.cvb-header-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  flex-shrink: 0;
}

.cvb-header-badge.completed {
  background: #ecfdf5;
  color: #059669;
  border: 1px solid #a7f3d0;
}

.cvb-header-badge.in-progress {
  background: #eff6ff;
  color: #2563eb;
  border: 1px solid #bfdbfe;
}

.cvb-chevron-icon {
  font-size: 0.8rem;
  color: #94a3b8;
  transition: transform 0.25s ease;
  flex-shrink: 0;
  margin-left: 8px;
}

.cvb-form-card.collapsed .cvb-chevron-icon {
  transform: rotate(-90deg);
}

.cvb-form-card.collapsed .cvb-form-body {
  display: none;
}

.cvb-form-body {
  padding: 1rem 1.15rem 1.25rem;
  border-top: 1px solid #f1f5f9;
}

/* ── Form Inputs ── */
.cvb-field-group {
  margin-bottom: 0.15rem;
}

.cvb-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.8rem;
  font-weight: 600;
  color: #475569;
  margin-bottom: 0.3rem;
}

.cvb-input,
.cvb-textarea,
.cvb-select {
  width: 100%;
  padding: 0.55rem 0.8rem;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 0.88rem;
  font-family: inherit;
  color: #0f172a;
  background: #ffffff;
  transition: all 0.15s ease;
  outline: none;
}

.cvb-input:focus,
.cvb-textarea:focus,
.cvb-select:focus {
  border-color: #8b5cf6;
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
}

.cvb-input::placeholder,
.cvb-textarea::placeholder {
  color: #9ca3af;
}

.cvb-textarea {
  min-height: 80px;
  resize: vertical;
}

.cvb-field-feedback {
  font-size: 0.72rem;
  font-weight: 600;
  margin-top: 3px;
  min-height: 14px;
}

.cvb-field-feedback.show-saved {
  color: #10b981;
}

.cvb-field-feedback.show-required {
  color: #ef4444;
}

.cvb-char-count {
  font-size: 0.7rem;
  color: #94a3b8;
  font-weight: 500;
}

/* ── Photo Upload ── */
.cvb-photo-dropzone-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1rem;
}

.cvb-dropzone {
  position: relative;
  border: 2px dashed #d1d5db;
  border-radius: 10px;
  background: #ffffff;
  padding: 1.5rem 1rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cvb-dropzone:hover,
.cvb-dropzone.drag-over {
  border-color: #8b5cf6;
  background: #f5f3ff;
}

.cvb-file-input-hidden {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  z-index: 5;
}

.cvb-dropzone-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  pointer-events: none;
}

.cvb-dropzone-icon-wrap {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #f5f3ff;
  color: #7c3aed;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
  transition: all 0.2s ease;
}

.cvb-dropzone:hover .cvb-dropzone-icon-wrap {
  background: #7c3aed;
  color: #ffffff;
  transform: scale(1.05);
}

.cvb-dropzone-title {
  font-size: 0.9rem;
  font-weight: 700;
  color: #1e293b;
  margin: 0 0 2px;
}

.cvb-dropzone-sub {
  font-size: 0.82rem;
  color: #64748b;
  margin: 0 0 3px;
}

.cvb-dropzone-hint {
  font-size: 0.72rem;
  color: #94a3b8;
}

.cvb-photo-preview-wrap {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 0.85rem;
}

.cvb-photo-thumbnail-box {
  position: relative;
  width: 80px;
  height: 95px;
  border-radius: 6px;
  overflow: hidden;
  border: 2px solid #8b5cf6;
  flex-shrink: 0;
}

.cvb-photo-thumbnail {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cvb-photo-overlay-badge {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(15, 23, 42, 0.85);
  color: #10b981;
  font-size: 0.6rem;
  font-weight: 700;
  text-align: center;
  padding: 2px 0;
}

.cvb-photo-details {
  flex: 1;
}

/* ── Repeater Items ── */
.cvb-repeater-item {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 0.85rem;
  margin-bottom: 0.75rem;
  position: relative;
  transition: all 0.15s ease;
}

.cvb-repeater-item:hover {
  border-color: #cbd5e1;
  background: #ffffff;
}

.cvb-item-delete-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 26px;
  height: 26px;
  border-radius: 6px;
  border: 1px solid #fecaca;
  background: #fff;
  color: #ef4444;
  display: grid;
  place-items: center;
  cursor: pointer;
  font-size: 0.7rem;
  transition: all 0.15s ease;
}

.cvb-item-delete-btn:hover {
  background: #fee2e2;
}

.cvb-add-item-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0.45rem 0.85rem;
  border-radius: 8px;
  font-size: 0.8rem;
  font-weight: 700;
  color: #7c3aed;
  background: #f5f3ff;
  border: 1.5px dashed #ddd6fe;
  cursor: pointer;
  transition: all 0.15s ease;
}

.cvb-add-item-btn:hover {
  background: #ede9fe;
  border-color: #a78bfa;
}

/* ── Bottom Action ── */
.cvb-bottom-action-wrap {
  text-align: center;
  margin: 2rem 0 3rem;
}

.cvb-animated-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 0.85rem 2.25rem;
  border-radius: 12px;
  background: #7c3aed;
  color: #ffffff !important;
  font-size: 1rem;
  font-weight: 700;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(124, 58, 237, 0.3);
  transition: all 0.2s ease;
  text-decoration: none;
}

.cvb-animated-btn:hover {
  background: #6d28d9;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(124, 58, 237, 0.4);
}

/* ══════════════════════════════════════════════════
   SMART COLLAPSIBLE SECTION DOCK (ICON-RAIL + DRAWER)
   ══════════════════════════════════════════════════ */
.cvb-section-dock {
  position: fixed;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  z-index: 1040;
  display: flex;
  align-items: stretch;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease;
  user-select: none;
}

/* ── 1. Mini Icon Rail (Docked on Right Edge when Collapsed) ── */
.cvb-dock-rail {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid #cbd5e1;
  border-right: none;
  border-radius: 16px 0 0 16px;
  box-shadow: -4px 6px 24px rgba(15, 23, 42, 0.12);
  padding: 8px 6px;
  z-index: 2;
  transition: all 0.25s ease;
}

/* When expanded, the mini rail is completely hidden */
.cvb-section-dock.expanded .cvb-dock-rail {
  display: none !important;
}

.cvb-dock-toggle-btn {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: #f5f3ff;
  border: 1px solid #ddd6fe;
  color: #7c3aed;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  margin-bottom: 4px;
}

.cvb-dock-toggle-btn:hover {
  background: #7c3aed;
  color: #ffffff;
  transform: scale(1.05);
}

.cvb-toggle-icon {
  font-size: 0.85rem;
  transition: transform 0.3s ease;
}

.cvb-rail-count-badge {
  font-size: 0.62rem;
  font-weight: 800;
  line-height: 1;
  margin-top: 2px;
}

.cvb-rail-icons-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.cvb-rail-icon-btn {
  position: relative;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: #f8fafc;
  border: 1px solid transparent;
  color: #64748b;
  display: grid;
  place-items: center;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.18s ease;
}

.cvb-rail-icon-btn:hover {
  background: #f5f3ff;
  color: #7c3aed;
  border-color: #ddd6fe;
  transform: translateX(-2px);
}

.cvb-rail-icon-btn.active {
  background: #7c3aed !important;
  color: #ffffff !important;
  border-color: #6d28d9;
  box-shadow: 0 3px 12px rgba(124, 58, 237, 0.4);
  transform: translateX(-3px) scale(1.06);
}

/* Completion status dot on rail */
.cvb-rail-status-dot {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #cbd5e1;
  transition: all 0.2s ease;
}

.cvb-rail-icon-btn.completed .cvb-rail-status-dot {
  background: #10b981;
  box-shadow: 0 0 6px rgba(16, 185, 129, 0.8);
}

.cvb-rail-icon-btn.active .cvb-rail-status-dot {
  background: #ffffff;
  box-shadow: 0 0 6px #ffffff;
}

/* Floating Tooltips on Hover for Rail Icons */
.cvb-rail-icon-btn::after {
  content: attr(data-tooltip);
  position: absolute;
  right: calc(100% + 12px);
  top: 50%;
  transform: translateY(-50%) scale(0.9);
  background: #0f172a;
  color: #ffffff;
  font-size: 0.76rem;
  font-weight: 700;
  padding: 5px 11px;
  border-radius: 7px;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 4px 14px rgba(0,0,0,0.25);
  z-index: 1060;
}

.cvb-rail-icon-btn::before {
  content: "";
  position: absolute;
  right: calc(100% + 6px);
  top: 50%;
  transform: translateY(-50%);
  border: 4px solid transparent;
  border-left-color: #0f172a;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease;
  z-index: 1060;
}

.cvb-rail-icon-btn:hover::after {
  opacity: 1;
  transform: translateY(-50%) scale(1);
}
.cvb-rail-icon-btn:hover::before {
  opacity: 1;
}

/* ── 2. Expanded Drawer Panel ── */
.cvb-dock-expanded-panel {
  width: 360px;
  max-width: calc(100vw - 20px);
  max-height: 86vh;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-right: none;
  border-radius: 18px 0 0 18px;
  box-shadow: -10px 0 35px rgba(15, 23, 42, 0.16);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 1;
}

/* Collapsed State hides panel completely */
.cvb-section-dock.collapsed .cvb-dock-expanded-panel {
  display: none !important;
}

.cvb-dock-header {
  padding: 1rem 1.25rem;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.cvb-dock-title {
  font-size: 0.96rem;
  font-weight: 800;
  color: #0f172a;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 7px;
}

.cvb-dock-subtitle {
  font-size: 0.72rem;
  color: #64748b;
  margin: 2px 0 0;
}

.cvb-dock-close-btn {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: transparent;
  border: 1px solid #e2e8f0;
  color: #64748b;
  display: grid;
  place-items: center;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.15s ease;
}
.cvb-dock-close-btn:hover {
  background: #fee2e2;
  border-color: #fecaca;
  color: #ef4444;
}

.cvb-dock-body {
  padding: 0.85rem 1rem;
  overflow-y: auto;
  flex: 1;
  scrollbar-width: thin;
}
.cvb-dock-body::-webkit-scrollbar {
  width: 5px;
}
.cvb-dock-body::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 5px;
}

.cvb-dock-footer {
  padding: 0.85rem 1rem;
  background: #f8fafc;
  border-top: 1px solid #e2e8f0;
}

.cvb-drawer-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.cvb-drawer-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0.65rem 0.8rem;
  border-radius: 10px;
  background: #ffffff;
  border: 1px solid #f1f5f9;
  cursor: pointer;
  transition: all 0.15s ease;
}

.cvb-drawer-item:hover {
  background: #f8fafc;
  border-color: #e2e8f0;
}

.cvb-drawer-item.active {
  background: #f5f3ff;
  border-color: #a78bfa;
}

.cvb-drawer-item-icon {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: #f1f5f9;
  color: #8b5cf6;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  flex-shrink: 0;
}

.cvb-drawer-item.active .cvb-drawer-item-icon {
  background: #7c3aed;
  color: #ffffff;
}

.cvb-drawer-item-content {
  flex: 1;
  min-width: 0;
}

.cvb-drawer-item-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  font-size: 0.82rem;
  font-weight: 700;
  color: #1e293b;
}

.cvb-drawer-item-desc {
  font-size: 0.7rem;
  color: #94a3b8;
  margin: 1px 0 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cvb-drawer-item-indicator {
  color: #d1d5db;
  font-size: 0.9rem;
  flex-shrink: 0;
}

.cvb-drawer-item.active .cvb-drawer-item-indicator,
.cvb-drawer-item.completed .cvb-drawer-item-indicator {
  color: #10b981;
}

@media (max-width: 768px) {
  .cvb-section-dock {
    top: auto;
    bottom: 16px;
    transform: none;
  }
  .cvb-dock-rail {
    border-radius: 14px 0 0 14px;
    padding: 6px 4px;
    gap: 3px;
  }
  .cvb-rail-icon-btn {
    width: 32px;
    height: 32px;
    font-size: 0.82rem;
  }
  .cvb-dock-toggle-btn {
    width: 34px;
    height: 34px;
  }
  .cvb-dock-expanded-panel {
    position: fixed;
    bottom: 0;
    right: 0;
    left: 0;
    width: 100% !important;
    max-width: 100vw !important;
    max-height: 75vh;
    border-radius: 20px 20px 0 0;
    border-right: 1px solid #cbd5e1;
    transform: none;
  }
  .cvb-section-dock.collapsed .cvb-dock-expanded-panel {
    transform: translateY(100%);
  }
}

.cvb-drawer-item-content {
  flex: 1;
  min-width: 0;
}

.cvb-drawer-item-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  font-size: 0.82rem;
  font-weight: 700;
  color: #1e293b;
}

.cvb-drawer-item-desc {
  font-size: 0.7rem;
  color: #94a3b8;
  margin: 1px 0 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cvb-drawer-item-indicator {
  color: #d1d5db;
  font-size: 0.9rem;
  flex-shrink: 0;
}

.cvb-drawer-item.active .cvb-drawer-item-indicator,
.cvb-drawer-item.completed .cvb-drawer-item-indicator {
  color: #10b981;
}

/* ── Cropper Modal ── */
.cvb-cropper-stage {
  width: 100%;
  height: 380px;
  background: #0f172a;
  border-radius: 10px;
  overflow: hidden;
}

.cvb-cropper-stage img {
  display: block;
  max-width: 100%;
}

.cvb-cropper-stage .cropper-view-box {
  border-radius: 4px;
  outline: 2px solid rgba(139, 92, 246, 0.85);
}

.cvb-cropper-stage .cropper-line {
  background-color: #8b5cf6;
}

.cvb-cropper-stage .cropper-point {
  background-color: #8b5cf6;
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

/* ── Drawer Footer ── */
.cvb-drawer-footer {
  padding: 0.85rem 1rem;
  border-top: 1px solid #e2e8f0;
  background: #f8fafc;
}

/* ── Responsive ── */
@media (max-width: 768px) {
  .cvb-hero-title {
    font-size: 1.35rem;
  }

  .cvb-hero-sub {
    font-size: 0.85rem;
  }

  .cvb-hero-actions {
    gap: 8px;
  }

  .cvb-hero-btn {
    padding: 0.5rem 0.9rem;
    font-size: 0.8rem;
  }

  .cvb-form-header {
    padding: 0.75rem 1rem;
  }

  .cvb-form-body {
    padding: 0.85rem 1rem 1rem;
  }

  .cvb-status-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }

  .cvb-photo-preview-wrap {
    flex-direction: column;
    text-align: center;
  }

  .cvb-floating-drawer-btn {
    right: 12px;
    bottom: 16px;
    padding: 0.5rem 0.75rem;
  }
}

@media (max-width: 480px) {
  .cv-builder-wrap {
    padding: 1rem 0 3rem;
  }

  .cvb-hero-banner {
    padding: 0.5rem 0.5rem 1rem;
  }

  .cvb-hero-title {
    font-size: 1.15rem;
  }

  .cvb-form-card {
    border-radius: 12px;
    margin-bottom: 0.75rem;
  }

  .cvb-form-header h3 {
    font-size: 0.88rem;
  }

  .cvb-input,
  .cvb-textarea {
    padding: 0.5rem 0.7rem;
    font-size: 0.85rem;
  }
}

/* ══════════════════════════════════════════════════
   LIVE CV PREVIEW & ATS PAPER STYLES
   ══════════════════════════════════════════════════ */
.cv-page {
  width: 210mm;
  min-height: 297mm;
  padding: 0.5in;
  margin: 0 auto;
  background: #ffffff;
  color: #111827;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 9.5pt;
  line-height: 1.35;
  box-sizing: border-box;
  position: relative;
  text-align: left;
}

[contenteditable="true"] {
  outline: none;
  transition: background 0.15s ease;
  border-radius: 2px;
}
[contenteditable="true"]:hover {
  background: rgba(139, 92, 246, 0.05);
}
[contenteditable="true"]:focus {
  background: rgba(139, 92, 246, 0.12);
  box-shadow: 0 0 0 1.5px rgba(139, 92, 246, 0.5);
}

/* ── CV Header ── */
.cv-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  border-bottom: 2px solid #111827;
  padding-bottom: 8pt;
  margin-bottom: 10pt;
}

.cv-header-text {
  flex: 1;
  min-width: 0;
}

.cv-name {
  font-family: Arial, Helvetica, sans-serif;
  font-size: 19pt;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 2pt 0;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  line-height: 1.15;
}

.cv-title {
  font-family: Arial, Helvetica, sans-serif;
  font-size: 10.5pt;
  font-weight: 700;
  color: #334155;
  margin-bottom: 5pt;
}

.cv-contact-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4pt 10pt;
  font-size: 8.8pt;
  color: #334155;
  line-height: 1.3;
}

.cv-contact-item {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.cv-contact-item i {
  color: #7c3aed;
  font-size: 8pt;
}

.cv-photo {
  width: 88px;
  height: 105px;
  object-fit: cover;
  border-radius: 4px;
  border: 1px solid #cbd5e1;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
  flex-shrink: 0;
}

/* ── CV Section ── */
.cv-section {
  margin-bottom: 9pt;
}

.cv-section-title {
  font-family: Arial, Helvetica, sans-serif;
  font-size: 10.5pt;
  font-weight: 800;
  color: #0f172a;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-bottom: 1.5px solid #334155;
  padding-bottom: 2pt;
  margin: 8pt 0 5pt 0;
}

.cv-objective-text {
  font-size: 9.2pt;
  color: #1f2937;
  text-align: justify;
  margin: 0;
  line-height: 1.42;
}

/* ── CV Item ── */
.cv-item {
  margin-bottom: 6pt;
}

.cv-item:last-child {
  margin-bottom: 0;
}

.cv-item-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
  font-size: 9.3pt;
}

.cv-item-title {
  font-weight: 700;
  color: #0f172a;
}

.cv-item-company {
  color: #1e293b;
  font-weight: 600;
}

.cv-item-date {
  font-size: 8.8pt;
  font-weight: 700;
  color: #475569;
  white-space: nowrap;
  flex-shrink: 0;
}

.cv-item-bullets {
  margin: 2.5pt 0 0 14pt;
  padding: 0;
  list-style-type: disc;
}

.cv-item-bullets li {
  font-size: 9pt;
  color: #334155;
  margin-bottom: 2pt;
  line-height: 1.38;
}

/* ── Academic Table ── */
.cv-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 3pt;
  font-size: 8.8pt;
}

.cv-table th,
.cv-table td {
  border: 1px solid #475569;
  padding: 4pt 6pt;
  text-align: left;
  vertical-align: middle;
}

.cv-table th {
  background: #f1f5f9;
  font-weight: 700;
  color: #0f172a;
}

.cv-table td strong {
  font-weight: 700;
  color: #0f172a;
}

/* ── Skills & Languages ── */
.cv-skill-group {
  font-size: 9pt;
  color: #1e293b;
  margin-bottom: 2.5pt;
  line-height: 1.38;
}

.cv-skill-group strong {
  color: #0f172a;
}

/* ── Personal Info Grid ── */
.cv-personal-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 3pt 16pt;
  font-size: 8.8pt;
  margin-top: 2pt;
}

.cv-personal-row {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.cv-personal-label {
  font-weight: 700;
  color: #334155;
  min-width: 110px;
  flex-shrink: 0;
}

.cv-personal-val {
  color: #0f172a;
  flex: 1;
}

/* ── References Grid ── */
.cv-ref-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12pt 20pt;
  margin-top: 4pt;
}

.cv-ref-card {
  font-size: 8.8pt;
  line-height: 1.35;
}

.cv-ref-name {
  font-weight: 700;
  font-size: 9.3pt;
  color: #0f172a;
}

.cv-ref-detail {
  color: #334155;
}

.cv-ref-sign-top-wrap {
  margin-bottom: 4pt;
}

.cv-ref-sign-img {
  max-height: 32px;
  max-width: 120px;
  display: block;
}

.cv-ref-sign-line {
  width: 110px;
  border-top: 1px solid #334155;
  margin-top: 3pt;
  margin-bottom: 4pt;
}

/* ── Download Action Buttons (Sleek Modern) ── */
.button-download {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0.5rem 1.15rem;
  border-radius: 999px;
  font-size: 0.84rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  border: none;
  transition: all 0.22s ease;
  user-select: none;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.button-download:hover {
  transform: translateY(-1.5px);
}

.button-download:active {
  transform: translateY(0);
}

.button-download.btn-pdf {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: #ffffff !important;
  box-shadow: 0 4px 14px rgba(220, 38, 38, 0.35);
}
.button-download.btn-pdf:hover {
  background: linear-gradient(135deg, #dc2626, #b91c1c);
  box-shadow: 0 6px 18px rgba(220, 38, 38, 0.45);
}

.button-download.btn-word {
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #ffffff !important;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35);
}
.button-download.btn-word:hover {
  background: linear-gradient(135deg, #1d4ed8, #1e40af);
  box-shadow: 0 6px 18px rgba(37, 99, 235, 0.45);
}

.button__icon {
  font-size: 0.95rem;
}

/* ── Black & White CV (no color) ──────────────────────────────────
   Forces the CV document to render purely in black / white / grayscale.
   Overrides all colored CV-page styles so the preview, PDF and Word
   downloads stay clean and professional. */
.cv-page,
.cv-page * {
  color: #000000 !important;
  border-color: #000000 !important;
  background: transparent !important;
  box-shadow: none !important;
  text-shadow: none !important;
}
.cv-page .cv-name,
.cv-page .cv-title,
.cv-page .cv-section-title,
.cv-page .cv-item-title,
.cv-page .cv-item-company,
.cv-page .cv-item-date,
.cv-page .cv-skill-group strong,
.cv-page .cv-personal-label,
.cv-page .cv-personal-val,
.cv-page .cv-ref-name,
.cv-page .cv-table td strong {
  color: #000000 !important;
}
.cv-page .cv-objective-text,
.cv-page .cv-item-bullets li,
.cv-page .cv-skill-group,
.cv-page .cv-ref-detail {
  color: #111111 !important;
}
.cv-page .cv-contact-item i,
.cv-page .cv-contact-item .fa-solid,
.cv-page .cv-contact-item .fa-brands {
  color: #000000 !important;
}
.cv-page .cv-photo {
  border-color: #000000 !important;
  box-shadow: none !important;
}
.cv-page .cv-table th {
  background: #ffffff !important;
  color: #000000 !important;
}
.cv-page .cv-header,
.cv-page .cv-section-title {
  border-bottom-color: #000000 !important;
}
.cv-page .cv-ref-sign-line {
  border-top-color: #000000 !important;
}
.cv-page img {
  filter: grayscale(100%);
}

/* ── Print Styles ── */
@page {
  size: A4;
  margin: 0;
}

@media print {
  .cvb-wrapper,
  .cvb-hero-banner,
  .cvb-status-panel,
  .cvb-form-section,
  .cvb-bottom-action-wrap,
  .cvb-floating-drawer-btn,
  .cvb-drawer,
  .cvp-topbar-nav,
  .site-header,
  .site-footer,
  .cvb-hide-print {
    display: none !important;
  }
  .cvp-page-body,
  .cvp-workspace {
    background: transparent !important;
    padding: 0 !important;
    overflow: visible !important;
  }
  .cvp-paper-viewport {
    transform: none !important;
  }
  .cvp-paper-shadow {
    box-shadow: none !important;
  }
  .cv-page {
    padding: 0.5in !important;
    width: 100% !important;
    min-height: auto !important;
  }
}
