@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@600;700&family=Inter:wght@300;400;500;600;700;800&family=Merriweather:ital,wght@0,300;0,400;0,700;1,300&family=Noto+Sans+Bengali:wght@400;500;600;700&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
  --bd-green: #006a4e;
  --bd-green-hover: #005a42;
  --bd-red: #f42a41;
}

body {
  font-family: 'Inter', 'Noto Sans Bengali', sans-serif;
  background-color: #f1f5f9;
  color: #1e293b;
}

.passport-ratio {
  aspect-ratio: 35 / 45;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
}

/* Cross-browser Custom Range Input */
input[type=range] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  background: transparent;
}

input[type=range]:focus {
  outline: none;
}

/* Webkit (Chrome, Safari, Edge) */
input[type=range]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  height: 18px;
  width: 18px;
  border-radius: 50%;
  background: #2563eb;
  cursor: pointer;
  margin-top: -7px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.15);
  border: 2px solid white;
  transition: all 0.2s ease;
}

input[type=range]:active::-webkit-slider-thumb {
  transform: scale(1.2);
  background: #1d4ed8;
}

input[type=range]::-webkit-slider-runnable-track {
  width: 100%;
  height: 4px;
  cursor: pointer;
  background: #e2e8f0;
  border-radius: 2px;
}

/* Firefox */
input[type=range]::-moz-range-thumb {
  height: 18px;
  width: 18px;
  border: 2px solid white;
  border-radius: 50%;
  background: #2563eb;
  cursor: pointer;
  box-shadow: 0 2px 4px rgba(0,0,0,0.15);
  transition: all 0.2s ease;
}

input[type=range]:active::-moz-range-thumb {
  transform: scale(1.2);
}

input[type=range]::-moz-range-track {
  width: 100%;
  height: 4px;
  cursor: pointer;
  background: #e2e8f0;
  border-radius: 2px;
}

/* Custom UI Components */
.glass-card {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.3);
}

.btn-bd-green {
  background-color: var(--bd-green);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-bd-green:hover {
  background-color: var(--bd-green-hover);
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(0, 106, 78, 0.3);
}

.animate-float {
  animation: float 3s ease-in-out infinite;
}

@keyframes float {
  0% { transform: translateY(0px); }
  50% { transform: translateY(-5px); }
  100% { transform: translateY(0px); }
}

.shimmer {
  background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* =========================================
   2-Page Professional CV Styles & Print Mode
   Executive Aesthetic & Bangladeshi Standard
   ========================================= */

.cv-page {
  width: 210mm;
  min-height: 297mm;
  padding: 14mm 16mm;
  margin: 0 auto 30px auto;
  background: #ffffff;
  box-shadow: 0 15px 35px -5px rgba(15, 23, 42, 0.15), 0 0 0 1px rgba(15, 23, 42, 0.06);
  border-radius: 4px;
  box-sizing: border-box;
  position: relative;
  font-family: 'Times New Roman', Times, 'Liberation Serif', serif;
  color: #1e293b;
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
  transition: all 0.25s ease;
}

/* Font Family Variants */
.cv-page.font-sans-mode {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

.cv-page.font-serif-mode {
  font-family: 'Merriweather', 'Times New Roman', Times, Georgia, serif !important;
}

/* =========================================
   THEMES: Executive Modern Banners & Accents
   ========================================= */

/* 1. Theme: Executive Royal Navy (Default) */
.cv-theme-navy .cv-banner-header {
  background: linear-gradient(135deg, #0e2a47 0%, #1e4976 50%, #15385f 100%);
  color: #ffffff;
  border: 1px solid #0a2037;
  box-shadow: 0 1px 3px rgba(14, 42, 71, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}
.cv-theme-navy .cv-accent-line {
  background: linear-gradient(90deg, #0e2a47 0%, #2563eb 50%, #93c5fd 100%);
}
.cv-theme-navy .cv-accent-text {
  color: #1e4976;
}
.cv-theme-navy .cv-table th {
  background: #f1f5f9;
  color: #0f172a;
  border-bottom: 2px solid #1e4976;
}
.cv-theme-navy .cv-photo-frame {
  border-color: #1e4976;
  box-shadow: 0 4px 10px -2px rgba(14, 42, 71, 0.2);
}

/* 2. Theme: Classic BD Upgraded Gradient (Authentic yet stunning) */
.cv-theme-classic .cv-banner-header {
  background: linear-gradient(180deg, #8baecf 0%, #d8e5f2 48%, #8baecf 100%);
  color: #08213d;
  border: 1px solid #709bc3;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8), 0 1px 2px rgba(0, 0, 0, 0.08);
}
.cv-theme-classic .cv-accent-line {
  background: linear-gradient(90deg, #709bc3 0%, #2563eb 50%, #709bc3 100%);
}
.cv-theme-classic .cv-accent-text {
  color: #08213d;
}
.cv-theme-classic .cv-table th {
  background: #edf3f8;
  color: #08213d;
  border-bottom: 2px solid #709bc3;
}
.cv-theme-classic .cv-photo-frame {
  border-color: #709bc3;
  box-shadow: 0 3px 8px -2px rgba(8, 33, 61, 0.15);
}

/* 3. Theme: Emerald Prestige */
.cv-theme-emerald .cv-banner-header {
  background: linear-gradient(135deg, #064e3b 0%, #047857 50%, #065f46 100%);
  color: #ffffff;
  border: 1px solid #044333;
  box-shadow: 0 1px 3px rgba(6, 78, 59, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}
.cv-theme-emerald .cv-accent-line {
  background: linear-gradient(90deg, #064e3b 0%, #059669 50%, #a7f3d0 100%);
}
.cv-theme-emerald .cv-accent-text {
  color: #065f46;
}
.cv-theme-emerald .cv-table th {
  background: #ecfdf5;
  color: #064e3b;
  border-bottom: 2px solid #047857;
}
.cv-theme-emerald .cv-photo-frame {
  border-color: #047857;
  box-shadow: 0 4px 10px -2px rgba(6, 78, 59, 0.2);
}

/* 4. Theme: Modern Slate / Charcoal */
.cv-theme-slate .cv-banner-header {
  background: linear-gradient(135deg, #1e293b 0%, #334155 50%, #0f172a 100%);
  color: #ffffff;
  border: 1px solid #0f172a;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}
.cv-theme-slate .cv-accent-line {
  background: linear-gradient(90deg, #0f172a 0%, #475569 50%, #cbd5e1 100%);
}
.cv-theme-slate .cv-accent-text {
  color: #1e293b;
}
.cv-theme-slate .cv-table th {
  background: #f1f5f9;
  color: #0f172a;
  border-bottom: 2px solid #334155;
}
.cv-theme-slate .cv-photo-frame {
  border-color: #334155;
  box-shadow: 0 4px 10px -2px rgba(15, 23, 42, 0.2);
}

/* 5. Theme: Burgundy Elite */
.cv-theme-burgundy .cv-banner-header {
  background: linear-gradient(135deg, #4c0519 0%, #881337 50%, #9f1239 100%);
  color: #ffffff;
  border: 1px solid #4c0519;
  box-shadow: 0 1px 3px rgba(76, 5, 25, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}
.cv-theme-burgundy .cv-accent-line {
  background: linear-gradient(90deg, #4c0519 0%, #be123c 50%, #fecdd3 100%);
}
.cv-theme-burgundy .cv-accent-text {
  color: #881337;
}
.cv-theme-burgundy .cv-table th {
  background: #fff1f2;
  color: #881337;
  border-bottom: 2px solid #9f1239;
}
.cv-theme-burgundy .cv-photo-frame {
  border-color: #881337;
  box-shadow: 0 4px 10px -2px rgba(76, 5, 25, 0.2);
}

/* Common Banner Header Styling */
.cv-banner-header {
  font-size: 13.5px;
  font-weight: 800;
  text-align: center;
  padding: 4px 12px;
  margin-top: 10px;
  margin-bottom: 7px;
  border-radius: 4px;
  letter-spacing: 0.4px;
  text-transform: capitalize;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
}

/* Academic & Corporate Bordered Tables */
.cv-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  overflow: hidden;
}

.cv-table th,
.cv-table td {
  border-right: 1px solid #cbd5e1;
  border-bottom: 1px solid #cbd5e1;
  padding: 4px 8px;
  font-size: 11.5px;
  color: #1e293b;
  vertical-align: middle;
}

.cv-table th:last-child,
.cv-table td:last-child {
  border-right: none;
}

.cv-table tr:last-child td {
  border-bottom: none;
}

.cv-table th {
  font-weight: 700;
  text-align: left;
  letter-spacing: 0.2px;
  font-size: 11.5px;
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
}

.cv-table tbody tr:nth-child(even) td {
  background-color: #f8fafc;
}

.cv-bullet-list {
  padding-left: 18px;
}

.cv-bullet-list li {
  line-height: 1.45;
  color: #1e293b;
  margin-bottom: 3px;
  position: relative;
}

.cv-card-box {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  padding: 7px 10px;
}

/* Print Rules - Generates perfect 2-page A4 PDF output */
@media print {
  @page {
    size: A4 portrait;
    margin: 8mm 10mm;
  }

  body {
    background-color: #ffffff !important;
    color: #000000 !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  /* Hide all website navigation, editor panels, ads, modals */
  #site-navbar,
  footer,
  #section-photo-tool,
  #section-blog-news,
  #slot-header-ad,
  #slot-footer-ad,
  .cv-editor-panel,
  .cv-action-bar,
  .no-print {
    display: none !important;
  }

  #section-cv-maker {
    display: block !important;
    padding: 0 !important;
    margin: 0 !important;
    max-width: 100% !important;
  }

  .cv-preview-container {
    display: block !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  .cv-page {
    width: 100% !important;
    min-height: 280mm !important;
    box-shadow: none !important;
    border: none !important;
    margin: 0 !important;
    padding: 10mm 12mm !important;
    page-break-after: always !important;
    break-after: page !important;
    border-radius: 0 !important;
  }

  .cv-page:last-child {
    page-break-after: auto !important;
    break-after: auto !important;
  }

  /* Force background colors and gradients to print */
  * {
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }
}

/* ========================================================
   Mobile Optimization for iOS (iPhone) & Android
   ======================================================== */
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  overflow-x: hidden;
  -webkit-tap-highlight-color: transparent;
  padding-bottom: env(safe-area-inset-bottom, 0px);
}

/* Prevent iOS Safari auto-zoom on input focus */
@media screen and (max-width: 768px) {
  input[type="text"],
  input[type="email"],
  input[type="password"],
  input[type="number"],
  input[type="tel"],
  input[type="url"],
  select,
  textarea {
    font-size: 16px !important;
  }
}

/* iOS momentum scrolling on all swipeable containers */
.overflow-x-auto,
.overflow-y-auto {
  -webkit-overflow-scrolling: touch;
}

/* Hide scrollbars cleanly on mobile tabs & sliders */
.scrollbar-none::-webkit-scrollbar {
  display: none;
}
.scrollbar-none {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

/* Touch optimization for mobile buttons & controls */
@media screen and (max-width: 640px) {
  button:not(.btn-icon-sm),
  a.btn {
    min-height: 42px;
  }

  /* Safe padding for fixed elements on iPhone with notch */
  .safe-bottom {
    padding-bottom: max(16px, env(safe-area-inset-bottom));
  }
}



