/* ─────────────────────────────────────────────────────────────────────────────
   MALIN CONSULTING — styles.css
   Dark premium consulting aesthetic · Instrument Sans · Scroll animations
───────────────────────────────────────────────────────────────────────────── */

/* ── Reset & base ─────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:        #0a0a0c;
  --surface:   #111114;
  --surface2:  #16161b;
  --border:    rgba(255,255,255,0.07);
  --text:      #e8e8f0;
  --muted:     #888899;
  --accent-y:  #f5d24a;   /* yellow  – data analytics */
  --accent-b:  #4a8ef5;   /* blue    – process optim. */
  --accent-r:  #f54a4a;   /* red     – AI impl.       */
  --radius:    12px;
  --radius-lg: 20px;
  --font: 'Instrument Sans', system-ui, sans-serif;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }

/* ── Scrollbar ─────────────────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.12); border-radius: 3px; }

/* ── Container ─────────────────────────────────────────────────────────────── */
.container {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 32px;
}

/* ── Buttons ───────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 8px;
  font-family: var(--font);
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  border: none;
  transition: all 0.2s var(--ease);
  text-decoration: none;
}
.btn-primary {
  background: var(--text);
  color: var(--bg);
}
.btn-primary:hover { background: #fff; transform: translateY(-1px); }

.btn-outline {
  border: 1px solid var(--border);
  color: var(--text);
  background: transparent;
}
.btn-outline:hover { border-color: rgba(255,255,255,0.25); background: rgba(255,255,255,0.04); }

.btn-ghost {
  color: var(--muted);
  background: transparent;
  padding: 10px 18px;
}
.btn-ghost:hover { color: var(--text); }

.btn-service {
  padding: 14px 28px;
  font-size: 15px;
  font-weight: 600;
}
.btn-yellow { background: var(--accent-y); color: #0a0a0c; }
.btn-yellow:hover { background: #f9dd6a; transform: translateY(-1px); }
.btn-blue   { background: var(--accent-b); color: #fff; }
.btn-blue:hover   { background: #6ba3ff; transform: translateY(-1px); }
.btn-red    { background: var(--accent-r); color: #fff; }
.btn-red:hover    { background: #ff6868; transform: translateY(-1px); }

/* ── Reveal animations ─────────────────────────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
.reveal.visible { opacity: 1; transform: translateY(0); }
.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }
.delay-3 { transition-delay: 0.3s; }
.delay-4 { transition-delay: 0.45s; }

/* ── Header / Nav ──────────────────────────────────────────────────────────── */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  background: rgba(10,10,12,0.75);
  border-bottom: 1px solid var(--border);
  transition: background 0.3s;
}
.nav-inner {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 32px;
  height: 64px;
  display: flex;
  align-items: center;
  gap: 48px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 17px;
  font-weight: 700;
  flex-shrink: 0;
}
.logo-mark {
  width: 32px; height: 32px;
  background: var(--text);
  color: var(--bg);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 16px;
}
.logo-accent { color: var(--muted); font-weight: 400; }

.nav-links {
  display: flex;
  gap: 32px;
  flex: 1;
}
.nav-link {
  font-size: 14px;
  color: var(--muted);
  transition: color 0.2s;
  position: relative;
}
.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px; left: 0;
  width: 0; height: 1px;
  background: var(--text);
  transition: width 0.2s;
}
.nav-link:hover, .nav-link.active { color: var(--text); }
.nav-link:hover::after, .nav-link.active::after { width: 100%; }

.nav-cta { margin-left: auto; }
.burger { display: none; flex-direction: column; gap: 5px; cursor: pointer; background: none; border: none; padding: 8px; }
.burger span { display: block; width: 22px; height: 1.5px; background: var(--text); transition: all 0.3s; }

.mobile-menu {
  display: none;
  flex-direction: column;
  padding: 16px 32px 20px;
  border-top: 1px solid var(--border);
  background: rgba(10,10,12,0.95);
  gap: 4px;
}
.mobile-menu.open { display: flex; }
.mobile-link {
  padding: 12px 0;
  font-size: 16px;
  color: var(--muted);
  border-bottom: 1px solid var(--border);
}
.mobile-link.highlight { color: var(--text); font-weight: 600; border-bottom: none; }

/* ── Hero ──────────────────────────────────────────────────────────────────── */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 120px 0 80px;
  position: relative;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.18;
}
.orb-1 { width: 600px; height: 600px; background: #4a8ef5; top: -100px; right: -100px; animation: drift 14s ease-in-out infinite alternate; }
.orb-2 { width: 400px; height: 400px; background: #f5d24a; bottom: -50px; left: 10%; animation: drift 18s ease-in-out infinite alternate-reverse; }
.orb-3 { width: 300px; height: 300px; background: #f54a4a; top: 40%; left: 55%; animation: drift 10s ease-in-out infinite alternate; }

@keyframes drift { 0% { transform: translate(0,0) scale(1); } 100% { transform: translate(40px, 30px) scale(1.08); } }

.grid-overlay {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
  background-size: 80px 80px;
  mask-image: radial-gradient(ellipse at 50% 50%, black 30%, transparent 80%);
}

.hero-inner { position: relative; z-index: 1; max-width: 700px; }

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  border-radius: 99px;
  border: 1px solid var(--border);
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 32px;
  background: rgba(255,255,255,0.03);
}

.hero-title {
  font-size: clamp(42px, 6vw, 72px);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.03em;
  margin-bottom: 24px;
}
.gradient-text {
  background: linear-gradient(135deg, #f5d24a 0%, #f54a4a 50%, #4a8ef5 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-sub {
  font-size: 18px;
  color: var(--muted);
  max-width: 540px;
  margin-bottom: 40px;
  line-height: 1.7;
}
.hero-ctas { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 60px; }

.hero-stats {
  display: flex;
  align-items: center;
  gap: 32px;
  flex-wrap: wrap;
}
.stat { display: flex; flex-direction: column; gap: 4px; }
.stat-num { font-size: 28px; font-weight: 700; letter-spacing: -0.02em; }
.stat-label { font-size: 13px; color: var(--muted); }
.stat-divider { width: 1px; height: 40px; background: var(--border); }

.scroll-indicator {
  position: absolute;
  bottom: 32px; left: 50%;
  transform: translateX(-50%);
  display: flex; flex-direction: column;
  align-items: center; gap: 8px;
  color: var(--muted); font-size: 11px;
  letter-spacing: 0.1em; text-transform: uppercase;
}
.scroll-line {
  width: 1px; height: 40px;
  background: linear-gradient(to bottom, var(--muted), transparent);
  animation: scrollPulse 1.8s ease-in-out infinite;
}
@keyframes scrollPulse { 0%,100% { opacity: 0.4; } 50% { opacity: 1; } }

/* ── Service blocks ────────────────────────────────────────────────────────── */
.service-block {
  padding: 120px 0;
  position: relative;
  border-top: 1px solid var(--border);
}
.service-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}
[data-color="yellow"] .service-bg {
  background: radial-gradient(ellipse 60% 40% at 90% 50%, rgba(245,210,74,0.04) 0%, transparent 70%);
}
.section-bg-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  z-index: 0;
}
.section-bg-overlay {
  position: absolute;
  inset: 0;
  background: rgba(10,10,12,0.72);
  z-index: 1;
}
[data-color="yellow"] .service-bg .section-bg-overlay {
  background: linear-gradient(rgba(10,10,12,0.70), rgba(10,10,12,0.75));
}
[data-color="blue"] .service-bg {
  background: radial-gradient(ellipse 60% 40% at 10% 50%, rgba(74,142,245,0.04) 0%, transparent 70%);
}
[data-color="red"] .service-bg {
  background: radial-gradient(ellipse 60% 40% at 90% 50%, rgba(245,74,74,0.04) 0%, transparent 70%);
}
.service-block .container { position: relative; z-index: 1; }

.service-header { margin-bottom: 64px; max-width: 640px; }
.service-tag {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: 4px;
  margin-bottom: 20px;
}
.tag-yellow { background: rgba(245,210,74,0.12); color: var(--accent-y); }
.tag-blue   { background: rgba(74,142,245,0.12); color: var(--accent-b); }
.tag-red    { background: rgba(245,74,74,0.12);  color: var(--accent-r); }

.service-title {
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.15;
  margin-bottom: 18px;
}
.service-title em { font-style: normal; color: var(--muted); }
.service-desc {
  font-size: 17px;
  color: var(--muted);
  line-height: 1.7;
}

/* ── Process steps ─────────────────────────────────────────────────────────── */
.process-label, .cases-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 24px;
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 72px;
}
.step-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  position: relative;
  overflow: hidden;
  transition: border-color 0.25s, transform 0.25s var(--ease), background 0.25s;
  cursor: default;
}
.step-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.03) 0%, transparent 60%);
  pointer-events: none;
}
.step-card:hover {
  border-color: rgba(255,255,255,0.15);
  transform: translateY(-3px);
  background: var(--surface2);
}
.step-num {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin-bottom: 20px;
}
.step-icon {
  font-size: 20px;
  margin-bottom: 14px;
  opacity: 0.6;
}
.step-card h3 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 10px;
  line-height: 1.3;
}
.step-card p {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.65;
}

/* ── Case cards ────────────────────────────────────────────────────────────── */
.cases-label { margin-top: 0; }
.cases-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 56px;
}
.case-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: border-color 0.25s, transform 0.25s var(--ease);
}
.case-card:hover {
  border-color: rgba(255,255,255,0.15);
  transform: translateY(-2px);
}
.case-industry {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}
.case-title {
  font-size: 16px;
  font-weight: 600;
  line-height: 1.4;
}
.case-desc {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.6;
  flex: 1;
}
.case-tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.tag {
  font-size: 12px;
  padding: 3px 10px;
  border-radius: 4px;
  background: rgba(255,255,255,0.06);
  color: var(--muted);
  border: 1px solid var(--border);
}
.case-result {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}
.result-num {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.result-label {
  font-size: 13px;
  color: var(--muted);
}
[data-color="yellow"] .result-num { color: var(--accent-y); }
[data-color="blue"]   .result-num { color: var(--accent-b); }
[data-color="red"]    .result-num { color: var(--accent-r); }

/* ── Inline form ───────────────────────────────────────────────────────────── */
.service-cta-wrap { display: flex; flex-direction: column; gap: 0; }

.inline-form {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.5s var(--ease), opacity 0.4s, margin-top 0.4s;
  opacity: 0;
  margin-top: 0;
}
.inline-form.open {
  max-height: 500px;
  opacity: 1;
  margin-top: 24px;
}

.contact-form {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-width: 600px;
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.contact-form input,
.contact-form textarea {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 16px;
  font-family: var(--font);
  font-size: 15px;
  color: var(--text);
  outline: none;
  transition: border-color 0.2s;
  width: 100%;
  resize: vertical;
}
.contact-form input::placeholder,
.contact-form textarea::placeholder { color: var(--muted); }
.contact-form input:focus,
.contact-form textarea:focus { border-color: rgba(255,255,255,0.3); }
.contact-form .btn { align-self: flex-start; }

.form-success {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 32px;
  text-align: center;
  color: var(--muted);
}
.form-success.show { display: flex; }
.success-icon {
  width: 44px; height: 44px;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  color: var(--text);
}

/* ── Contact strip ─────────────────────────────────────────────────────────── */
.contact-strip {
  padding: 100px 0;
  background: var(--surface);
  border-top: 1px solid var(--border);
}
.contact-inner {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 64px;
  align-items: start;
}
.contact-text h2 {
  font-size: 36px;
  font-weight: 700;
  letter-spacing: -0.025em;
  margin-bottom: 12px;
}
.contact-text p {
  font-size: 16px;
  color: var(--muted);
  line-height: 1.6;
}
.contact-strip-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.strip-fields {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 14px;
}
.contact-strip-form input,
.contact-strip-form textarea {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 16px;
  font-family: var(--font);
  font-size: 15px;
  color: var(--text);
  outline: none;
  transition: border-color 0.2s;
  width: 100%;
  resize: vertical;
}
.contact-strip-form input::placeholder,
.contact-strip-form textarea::placeholder { color: var(--muted); }
.contact-strip-form input:focus,
.contact-strip-form textarea:focus { border-color: rgba(255,255,255,0.3); }
.strip-success { padding: 20px 0; }

/* ── Footer ────────────────────────────────────────────────────────────────── */
.footer {
  background: var(--bg);
  border-top: 1px solid var(--border);
  padding: 64px 0 0;
}
.footer-inner {
  display: grid;
  grid-template-columns: 1.2fr 2fr;
  gap: 64px;
  padding-bottom: 64px;
}
.footer-brand { display: flex; flex-direction: column; gap: 16px; }
.footer-tagline { font-size: 14px; color: var(--muted); line-height: 1.6; max-width: 260px; }
.footer-links { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.footer-col { display: flex; flex-direction: column; gap: 12px; }
.footer-col h5 { font-size: 12px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.footer-col a { font-size: 14px; color: var(--muted); transition: color 0.2s; }
.footer-col a:hover { color: var(--text); }
.footer-bottom {
  border-top: 1px solid var(--border);
  padding: 20px 32px;
  max-width: 1160px;
  margin: 0 auto;
  font-size: 13px;
  color: var(--muted);
}

/* ── Responsive ────────────────────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .steps-grid { grid-template-columns: repeat(2, 1fr); }
  .cases-grid { grid-template-columns: repeat(2, 1fr); }
  .contact-inner { grid-template-columns: 1fr; gap: 40px; }
  .strip-fields { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .nav-links, .nav-cta { display: none; }
  .burger { display: flex; margin-left: auto; }
  .container { padding: 0 20px; }
  .hero { padding: 100px 0 60px; }
  .hero-title { font-size: 38px; }
  .hero-sub { font-size: 16px; }
  .hero-stats { gap: 20px; }
  .stat-num { font-size: 22px; }
  .service-block { padding: 80px 0; }
  .service-title { font-size: 30px; }
  .steps-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .cases-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .strip-fields { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr; gap: 40px; }
  .footer-links { grid-template-columns: repeat(2, 1fr); }
  .contact-strip { padding: 72px 0; }
}

@media (max-width: 480px) {
  .steps-grid { grid-template-columns: 1fr; }
  .hero-title { font-size: 32px; }
  .hero-ctas { flex-direction: column; }
  .hero-ctas .btn { text-align: center; justify-content: center; }
  .footer-links { grid-template-columns: 1fr; }
}
