/* Mizan HR Consulting — custom styles (Tailwind CDN handles utility classes) */

@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('../fonts/PlusJakartaSans-Variable.woff2') format('woff2-variations'), url('../fonts/PlusJakartaSans-Variable.woff2') format('woff2');
}

html { font-size: 16px; }

.scrollbar-hide { scrollbar-width: none; -ms-overflow-style: none; }
.scrollbar-hide::-webkit-scrollbar { display: none; }

:root {
  --mizan-navy: #0B6E4F;
  --mizan-blue: #159957;
  --mizan-blue-hover: #0f7d47;
  --mizan-blue-shadow: 21,153,87;
  --mizan-emerald: #159957;
  --mizan-bg: #F9FAF7;
  --mizan-white: #FFFFFF;
  --mizan-text: #0F172A;
  --mizan-text-soft: #475569;
  --mizan-border: #E4E9E3;
  --mizan-soft-blue: #E7F5EC;
  --mizan-soft-green: #E7F5EC;
  --mizan-dark: #052E22;
}

/* Home page keeps the original gold accent; every other page uses green as primary. */
body.home {
  --mizan-blue: #B8860B;
  --mizan-blue-hover: #9c7009;
  --mizan-blue-shadow: 184,134,11;
  --mizan-soft-blue: #FBF3DA;
}

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

html, body {
  max-width: 100%;
}

body {
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  color: var(--mizan-text);
  background-color: var(--mizan-bg);
}

h1, h2, h3, h4, h5, h6, .font-display {
  font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
}

/* Skip link */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--mizan-navy);
  color: #fff;
  padding: 12px 20px;
  border-radius: 0 0 8px 0;
}
.skip-link:focus {
  left: 0;
}

/* Focus states */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid var(--mizan-blue);
  outline-offset: 2px;
  border-radius: 4px;
}

/* Scroll progress bar */
#scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0%;
  background: linear-gradient(90deg, var(--mizan-blue), var(--mizan-emerald));
  z-index: 60;
  transition: width 0.1s ease-out;
}

/* Reveal on scroll */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* Mobile nav */
#mobile-nav {
  transform: translateX(100%);
  transition: transform 0.3s ease;
}
#mobile-nav.is-open {
  transform: translateX(0);
}

/* Service card hover lift */
.service-card {
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.service-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px -20px rgba(22, 58, 95, 0.25);
  border-color: var(--mizan-blue);
}

/* Timeline connector (desktop/tablet grid only — hidden on the stacked mobile layout) */
@media (min-width: 768px) {
  .process-step::after {
    content: '';
    position: absolute;
    top: 28px;
    left: 100%;
    width: 100%;
    height: 2px;
    background: var(--mizan-border);
  }
  .process-step:last-child::after {
    display: none;
  }
}

/* Back to top */
#back-to-top {
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s;
}
#back-to-top.is-visible {
  opacity: 1;
  visibility: visible;
}

/* FAQ accordion */
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease;
}
.faq-item.is-open .faq-answer {
  max-height: 600px;
}
.faq-item.is-open .faq-icon {
  transform: rotate(45deg);
}
.faq-icon {
  transition: transform 0.25s ease;
}

/* Modal */
.modal-backdrop {
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s;
}
.modal-backdrop.is-open {
  opacity: 1;
  visibility: visible;
}
.modal-panel {
  transform: scale(0.96) translateY(10px);
  transition: transform 0.25s ease;
}
.modal-backdrop.is-open .modal-panel {
  transform: scale(1) translateY(0);
}

/* WhatsApp float button pulse */
@keyframes mizan-pulse {
  0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.45); }
  70% { box-shadow: 0 0 0 14px rgba(16, 185, 129, 0); }
  100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}
.pulse-cta {
  animation: mizan-pulse 2.5s infinite;
}

/* HR Health Check radial score */
.score-ring {
  transition: stroke-dashoffset 1s ease;
}

/* Utility: max content width */
.container-mizan {
  max-width: 1320px;
  margin-left: auto;
  margin-right: auto;
}

/* Section vertical rhythm — generous, airy spacing between page sections */
.section-y {
  padding-top: 112px;
  padding-bottom: 112px;
}
@media (max-width: 1024px) {
  .section-y { padding-top: 80px; padding-bottom: 80px; }
}
@media (max-width: 640px) {
  .section-y { padding-top: 56px; padding-bottom: 56px; }
}

/* Active nav link */
.nav-link.is-active {
  color: var(--mizan-blue);
}

/* Active insights filter button */
.filter-btn.is-active {
  background-color: var(--mizan-navy);
  border-color: var(--mizan-navy);
  color: #fff;
}
.nav-link.is-active::after {
  content: '';
  display: block;
  height: 2px;
  background: var(--mizan-blue);
  margin-top: 4px;
}

/* Range/checklist radio pills */
.pill-option input:checked + label {
  background-color: var(--mizan-navy);
  color: #fff;
  border-color: var(--mizan-navy);
}

/* ==========================================================================
   Component classes (buttons, nav panels, modal, cookie banner, etc.)
   ========================================================================== */

.btn-primary, .btn-secondary, .btn-outline, .btn-whatsapp, .btn-white {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 24px; border-radius: 8px; font-weight: 600; font-size: 15px;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease, color 0.15s ease;
  white-space: nowrap;
}
.btn-primary { background: var(--mizan-blue); color: #fff; }
.btn-primary:hover { background: var(--mizan-blue-hover); transform: translateY(-1px); box-shadow: 0 10px 24px rgba(var(--mizan-blue-shadow),0.28); }
.btn-secondary { background: var(--mizan-navy); color: #fff; }
.btn-secondary:hover { background: #094a35; transform: translateY(-1px); }
.btn-outline { background: transparent; color: var(--mizan-navy); border: 1.5px solid var(--mizan-border); }
.btn-outline:hover { border-color: var(--mizan-blue); color: var(--mizan-blue); }
.btn-whatsapp { background: #25D366; color: #fff; }
.btn-whatsapp:hover { background: #1fb959; transform: translateY(-1px); }
.btn-white { background: #fff; color: var(--mizan-navy); }
.btn-white:hover { background: #f1f5f9; transform: translateY(-1px); }

.card {
  border-radius: 8px;
  border: 1px solid var(--mizan-border);
  background: #fff;
  transition: border-color 0.2s ease;
}
.card:hover { border-color: var(--mizan-emerald); }

#site-nav { transition: box-shadow 0.25s ease; }
#site-nav.scrolled { box-shadow: 0 4px 20px rgba(15, 23, 42, 0.08); }

#mobile-nav {
  position: fixed; inset: 0 0 0 auto; width: min(340px, 88vw); z-index: 90;
  background: #fff; box-shadow: -10px 0 40px rgba(15,23,42,0.15);
  overflow-y: auto;
}

#scroll-progress { position: fixed; top: 0; left: 0; height: 3px; width: 0%; background: linear-gradient(90deg, var(--mizan-blue), var(--mizan-emerald)); z-index: 60; transition: width 0.1s ease-out; }

.wa-float {
  position: fixed; bottom: 24px; right: 24px; z-index: 55;
  width: 58px; height: 58px; border-radius: 50%; background: #25D366;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 10px 24px rgba(37,211,102,0.4);
  transition: transform 0.2s ease;
}
.wa-float:hover { transform: scale(1.08); }

#back-to-top {
  position: fixed; bottom: 24px; left: 24px; z-index: 55;
  width: 46px; height: 46px; border-radius: 50%; background: var(--mizan-navy); color: #fff;
  display: flex; align-items: center; justify-content: center;
}

#consult-modal.modal-backdrop {
  position: fixed; inset: 0; z-index: 95; display: flex; align-items: center; justify-content: center; padding: 20px;
  background: rgba(15,23,42,0.55);
}

.form-status { display: none; padding: 14px 16px; border-radius: 10px; margin-top: 16px; font-size: 14px; }
.form-status.success { background: var(--mizan-soft-green); color: #047857; border: 1px solid #a7f3d0; }
.form-status.error { background: #FEF2F2; color: #B91C1C; border: 1px solid #FECACA; }

.pill-choice {
  text-align: left; padding: 16px 20px; border: 1.5px solid var(--mizan-border); border-radius: 8px;
  font-weight: 600; transition: border-color 0.15s ease, background-color 0.15s ease, transform 0.15s ease;
}
.pill-choice:hover { border-color: var(--mizan-blue); background: var(--mizan-soft-blue); transform: translateY(-2px); }
.pill-choice.hc-yes:hover { border-color: var(--mizan-emerald); background: var(--mizan-soft-green); }
.pill-choice.hc-no:hover { border-color: #EF4444; background: #FEF2F2; }

#cookie-banner {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 92;
  background: var(--mizan-dark); color: #fff; padding: 18px 20px;
  transform: translateY(100%); transition: transform 0.3s ease;
}
#cookie-banner.is-visible { transform: translateY(0); }

body.modal-lock { overflow: hidden; }

[data-filter].is-active, [data-insight-filter].is-active { background: var(--mizan-navy) !important; color: #fff !important; }

[data-image-prompt] {
  background: linear-gradient(135deg, var(--mizan-soft-blue), var(--mizan-soft-green));
  display: flex; align-items: center; justify-content: center;
  color: #94A3B8; font-size: 12px; text-align: center; padding: 20px;
  border: 1px dashed #cbd5e1;
}

/* HR Trainings Page Styles */

.role-card {
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.role-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px -20px rgba(11, 110, 79, 0.25);
  border-color: var(--mizan-emerald);
}

.project-card {
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.project-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px -8px rgba(11, 110, 79, 0.2);
}

/* Certification badge */
.cert-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--mizan-soft-green);
  color: var(--mizan-emerald);
  font-size: 12px;
  font-weight: 700;
}
