/* ==========================================================================
   Nice PageBuilder — Frontend Component Styles  v2.1
   Design system inspired by GIMAVE web layout:
   • Sections: 80-100px vertical padding
   • Container: 1200px, 30px gutters
   • 2-col layout gap: 60px | 4-5 col: 20-24px
   • Cards: 12px radius, subtle shadow
   ========================================================================== */

/* ── Section base ───────────────────────────────────────────────────────── */
.nice-pb-section {
  padding: var(--nice-section-lg, 80px) 0;
  position: relative;
  width: 100%;
}

/* Size modifiers */
.nice-pb-section--hero { padding: var(--nice-section-hero, 100px) 0; }
.nice-pb-section--xl   { padding: var(--nice-section-xl,   100px) 0; }
.nice-pb-section--lg   { padding: var(--nice-section-lg,    80px) 0; }
.nice-pb-section--md   { padding: var(--nice-section-md,    60px) 0; }
.nice-pb-section--sm   { padding: var(--nice-section-sm,    40px) 0; }
.nice-pb-section--xs   { padding: var(--nice-section-xs,    24px) 0; }
.nice-pb-section--none { padding: 0; }

/* Container — wider gutters than the old 20px */
.nice-pb-section .nice__container,
.nice-pb-section > .nice__container {
  padding-left:  var(--nice-gutter, 30px);
  padding-right: var(--nice-gutter, 30px);
}

/* Section background image helper */
.nice-pb-section[style*="background-image"] {
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* Dark overlay shortcut — add class via custom_class */
.nice-pb-section--overlay::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.45);
  z-index: 1;
}
.nice-pb-section--overlay > * { position: relative; z-index: 2; }

/* ── Grid Row ───────────────────────────────────────────────────────────── */
.nice-pb-grid-row {
  display: grid;
  gap: var(--nice-gap, 30px);
  width: 100%;
}
.nice-pb-col { min-width: 0; position: relative; }

/* Column align helpers */
.nice-pb-grid-row .nice-pb-col--center { display: flex; flex-direction: column; justify-content: center; }
.nice-pb-grid-row .nice-pb-col--end    { display: flex; flex-direction: column; justify-content: flex-end; }

/* ── Image ──────────────────────────────────────────────────────────────── */
.nice-pb-image { margin: 0; }
.nice-pb-image img {
  max-width: 100%;
  height: auto;
  display: block;
  border-radius: inherit;
}
/* Full-height cover image (useful for 2-col sections) */
.nice-pb-image--cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: var(--nice-radius-md, 12px);
}

/* ── Title ──────────────────────────────────────────────────────────────── */
.nice-pb-title {
  line-height: var(--nice-lh-heading, 1.15);
  font-weight: 700;
  margin: 0 0 16px;
}
.nice-pb-title:last-child { margin-bottom: 0; }

/* ── Text ───────────────────────────────────────────────────────────────── */
.nice-pb-text { line-height: var(--nice-lh-body, 1.7); }
.nice-pb-text p          { margin: 0 0 1em; }
.nice-pb-text p:last-child { margin-bottom: 0; }
.nice-pb-text ul, .nice-pb-text ol { padding-left: 1.5em; margin: 0 0 1em; }
.nice-pb-text li         { margin-bottom: .4em; }

/* ── Button ─────────────────────────────────────────────────────────────── */
.nice-pb-button-wrap { display: block; }
.nice-pb-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 32px;
  border-radius: var(--nice-radius-pill, 50px);
  font-weight: 700;
  font-size: 15px;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  transition: background .18s, border-color .18s, color .18s, transform .1s, box-shadow .18s;
  border: 2px solid transparent;
  letter-spacing: .2px;
}
.nice-pb-button:active { transform: scale(.97); }

.nice-pb-button--primary {
  background: #3858e9;
  color: #fff;
  border-color: #3858e9;
}
.nice-pb-button--primary:hover {
  background: #2c47d0;
  border-color: #2c47d0;
  color: #fff;
  box-shadow: 0 4px 16px rgba(56,88,233,.35);
}

.nice-pb-button--secondary {
  background: #6c757d;
  color: #fff;
  border-color: #6c757d;
}
.nice-pb-button--secondary:hover { background: #5c636a; color: #fff; }

.nice-pb-button--outline {
  background: transparent;
  color: #3858e9;
  border-color: #3858e9;
}
.nice-pb-button--outline:hover { background: #3858e9; color: #fff; }

.nice-pb-button--ghost {
  background: transparent;
  color: inherit;
  border-color: currentColor;
}
.nice-pb-button--ghost:hover { background: rgba(0,0,0,.06); }

/* ── Gallery ────────────────────────────────────────────────────────────── */
.nice-pb-gallery {
  display: grid;
  gap: var(--nice-gap, 20px);
}
.nice-pb-gallery-item { display: block; overflow: hidden; border-radius: var(--nice-radius-md, 12px); }
.nice-pb-gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .4s ease;
}
.nice-pb-gallery-item:hover img { transform: scale(1.04); }

/* ── Icon ───────────────────────────────────────────────────────────────── */
.nice-pb-icon { display: block; line-height: 1; }
.nice-pb-icon i { display: inline-block; line-height: 1; vertical-align: middle; }
.nice-pb-icon__link {
  display: inline-block;
  text-decoration: none;
  color: inherit;
  transition: opacity .18s;
}
.nice-pb-icon__link:hover { opacity: .75; }

/* ==========================================================================
   Utility patterns (add via custom_class field)
   ========================================================================== */

/* ── Card ───────────────────────────────────────────────────────────────── */
.npb-card {
  background: #fff;
  border-radius: var(--nice-radius-md, 12px);
  box-shadow: var(--nice-shadow-md, 0 4px 16px rgba(0,0,0,.1));
  overflow: hidden;
  height: 100%;
}
.npb-card--bordered {
  background: #fff;
  border-radius: var(--nice-radius-md, 12px);
  border: 1px solid #e5e7eb;
  overflow: hidden;
  height: 100%;
}
.npb-card--dark {
  background: #0f2087;
  color: #fff;
  border-radius: var(--nice-radius-md, 12px);
  overflow: hidden;
  height: 100%;
}
.npb-card-body { padding: 28px 24px; }
.npb-card-body--lg { padding: 40px 32px; }

/* Service card: image at top, dark bg content at bottom */
.npb-service-card {
  border-radius: var(--nice-radius-md, 12px);
  overflow: hidden;
  box-shadow: var(--nice-shadow-md);
  height: 100%;
  display: flex;
  flex-direction: column;
}
.npb-service-card__img {
  position: relative;
  height: 240px;
  overflow: hidden;
}
.npb-service-card__img img { width: 100%; height: 100%; object-fit: cover; }
.npb-service-card__body {
  flex: 1;
  padding: 28px 24px 32px;
  background: #0f2087;
  color: #fff;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.npb-service-card__title { color: #ffd600; font-size: 20px; font-weight: 700; }
.npb-service-card__text  { font-size: 14px; line-height: 1.6; opacity: .9; flex: 1; }

/* ── Stats / counter item ───────────────────────────────────────────────── */
.npb-stat { text-align: center; padding: 16px 8px; }
.npb-stat__number {
  display: block;
  font-size: 48px;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 8px;
  letter-spacing: -1px;
}
.npb-stat__label {
  display: block;
  font-size: 14px;
  line-height: 1.4;
  opacity: .75;
}

/* ── Feature item (icon + title + text) ─────────────────────────────────── */
.npb-feature { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 12px; padding: 16px 8px; }
.npb-feature--left { align-items: flex-start; text-align: left; }
.npb-feature__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: rgba(56,88,233,.1);
  font-size: 28px;
  color: #3858e9;
  flex-shrink: 0;
}
.npb-feature__title { font-size: 17px; font-weight: 700; margin: 0; }
.npb-feature__text  { font-size: 14px; line-height: 1.6; opacity: .75; margin: 0; }

/* ── Checklist item ─────────────────────────────────────────────────────── */
.npb-check-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 14px; }
.npb-check-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 15px;
  line-height: 1.5;
}
.npb-check-list li::before {
  content: '';
  display: block;
  width: 20px;
  height: 20px;
  background: #3858e9;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 2px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 10'%3E%3Cpath d='M1 5l3 3 7-7' stroke='%23fff' stroke-width='1.8' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-size: 60%;
  background-repeat: no-repeat;
  background-position: center;
}

/* ── Testimonial card ───────────────────────────────────────────────────── */
.npb-testimonial {
  background: #fff;
  border-radius: var(--nice-radius-md, 12px);
  padding: 28px 24px;
  box-shadow: var(--nice-shadow-sm, 0 1px 4px rgba(0,0,0,.08));
  border: 1px solid #f0f0f0;
}
.npb-testimonial__header { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.npb-testimonial__avatar {
  width: 44px; height: 44px;
  border-radius: 50%;
  background: #e5e7eb;
  overflow: hidden;
  flex-shrink: 0;
}
.npb-testimonial__avatar img { width: 100%; height: 100%; object-fit: cover; }
.npb-testimonial__name  { font-weight: 700; font-size: 15px; }
.npb-testimonial__meta  { font-size: 12px; opacity: .6; }
.npb-testimonial__text  { font-size: 14px; line-height: 1.7; opacity: .8; }
.npb-testimonial__stars { color: #f5a623; font-size: 14px; letter-spacing: 1px; margin-top: 6px; }

/* ── CTA strip (dark bg, text + button) ─────────────────────────────────── */
.npb-cta-strip {
  background: #0f2087;
  color: #fff;
  padding: 60px 0;
  text-align: center;
}

/* ── Divider / separator ────────────────────────────────────────────────── */
.npb-divider { width: 60px; height: 4px; background: #3858e9; border-radius: 2px; margin: 0 0 24px; }
.npb-divider--center { margin: 0 auto 24px; }
.npb-divider--yellow { background: #ffd600; }

/* ── Text utilities ─────────────────────────────────────────────────────── */
.npb-text-center  { text-align: center; }
.npb-text-left    { text-align: left; }
.npb-text-right   { text-align: right; }
.npb-text-white   { color: #fff !important; }
.npb-text-muted   { opacity: .7; }
.npb-text-primary { color: #3858e9 !important; }
.npb-text-accent  { color: #ffd600 !important; }
.npb-font-light   { font-weight: 300; }
.npb-font-normal  { font-weight: 400; }
.npb-font-medium  { font-weight: 500; }
.npb-font-bold    { font-weight: 700; }
.npb-font-black   { font-weight: 900; }

/* ── Spacing utilities ──────────────────────────────────────────────────── */
.npb-mb-8  { margin-bottom:  8px !important; }
.npb-mb-16 { margin-bottom: 16px !important; }
.npb-mb-24 { margin-bottom: 24px !important; }
.npb-mb-32 { margin-bottom: 32px !important; }
.npb-mb-48 { margin-bottom: 48px !important; }
.npb-mb-64 { margin-bottom: 64px !important; }
.npb-mt-8  { margin-top:     8px !important; }
.npb-mt-16 { margin-top:    16px !important; }
.npb-mt-24 { margin-top:    24px !important; }
.npb-mt-32 { margin-top:    32px !important; }
.npb-mt-48 { margin-top:    48px !important; }
.npb-mt-64 { margin-top:    64px !important; }
.npb-pt-0  { padding-top:    0   !important; }
.npb-pb-0  { padding-bottom: 0   !important; }

/* ── Width helpers ──────────────────────────────────────────────────────── */
.npb-w-100 { width: 100%; }
.npb-mw-600 { max-width: 600px; }
.npb-mw-720 { max-width: 720px; }
.npb-mw-800 { max-width: 800px; }
.npb-mx-auto { margin-left: auto; margin-right: auto; }

/* ── Flex helpers ───────────────────────────────────────────────────────── */
.npb-flex-center { display: flex; align-items: center; justify-content: center; }
.npb-flex-between { display: flex; align-items: center; justify-content: space-between; }
.npb-gap-8  { gap:  8px; }
.npb-gap-12 { gap: 12px; }
.npb-gap-16 { gap: 16px; }
.npb-gap-24 { gap: 24px; }

/* ==========================================================================
   Responsive overrides
   ========================================================================== */
@media (max-width: 1024px) {
  .nice-pb-section        { padding: 70px 0; }
  .nice-pb-section--hero  { padding: 80px 0; }
  .nice-pb-section--xl    { padding: 80px 0; }
}
@media (max-width: 768px) {
  .nice-pb-section        { padding: 56px 0; }
  .nice-pb-section--hero  { padding: 64px 0; }
  .nice-pb-section--xl    { padding: 64px 0; }
  .nice-pb-section--lg    { padding: 56px 0; }
  .nice-pb-section--md    { padding: 40px 0; }
  .nice__container { padding-left: 20px; padding-right: 20px; }
  .npb-stat__number { font-size: 36px; }
  .nice-pb-button  { padding: 12px 24px; font-size: 14px; }
}
@media (max-width: 480px) {
  .nice-pb-section  { padding: 48px 0; }
  .nice__container  { padding-left: 16px; padding-right: 16px; }
}
