/* Malina IT — Napoleon-inspired (Webflow-like) */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700&display=swap');

:root {
  color-scheme: dark;
  --bg: #09090b;
  --surface: #111114;
  --surface-2: #18181c;
  --white: #ffffff;
  --text: #f4f4f5;
  --text-inverse: #0a0a0b;
  --muted: #a1a1aa;
  --grey: #71717a;
  --border: rgba(255, 255, 255, 0.1);
  --border-strong: rgba(255, 255, 255, 0.16);
  --purple: #6d5cff;
  --purple-bright: #8b7cff;
  --purple-soft: #b794f6;
  --hero-fallback: var(--surface);
  --header-h: 76px;
  --container: 1280px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
html.no-scroll { overflow: hidden; }
body {
  font-family: 'Montserrat', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button { font: inherit; cursor: pointer; border: none; background: none; }

.page-loader {
  position: fixed; inset: 0; z-index: 9999;
  background: var(--bg);
  display: flex; align-items: center; justify-content: center;
  transition: opacity 0.6s var(--ease), visibility 0.6s;
}
.page-loader.is-done { opacity: 0; visibility: hidden; pointer-events: none; }
.loader-mark {
  width: 48px; height: 48px; border-radius: 12px;
  background: linear-gradient(135deg, var(--purple-soft), var(--purple));
  animation: loader-pulse 1.2s ease-in-out infinite;
}
@keyframes loader-pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(0.92); opacity: 0.7; }
}

.page-root { opacity: 0; transition: opacity 0.5s var(--ease); }
.page-root.is-ready { opacity: 1; }

.container {
  width: min(100% - 48px, var(--container));
  margin-inline: auto;
}

/* Header */
.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  height: var(--header-h);
  transition: background 0.35s, box-shadow 0.35s;
}
.site-header.is-scrolled {
  background: rgba(9, 9, 11, 0.88);
  backdrop-filter: blur(14px);
  box-shadow: 0 1px 0 var(--border);
}
.header-row {
  height: 100%;
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
}
.brand {
  display: flex; align-items: center; gap: 10px;
  font-weight: 700; font-size: 0.95rem; letter-spacing: -0.02em;
}
.brand img { width: 36px; height: 36px; border-radius: 8px; object-fit: cover; }
.nav {
  display: none;
  gap: 28px;
  font-size: 0.72rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.08em;
}
.nav a { opacity: 0.75; transition: opacity 0.2s; }
.nav a:hover { opacity: 1; }
.btn-pill {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 14px 22px; border-radius: 999px;
  background: var(--white); color: var(--text-inverse);
  font-size: 0.72rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.06em;
  transition: transform 0.2s, background 0.2s, box-shadow 0.2s;
}
.btn-pill:hover {
  transform: translateY(-1px);
  background: var(--purple-bright);
  color: var(--white);
  box-shadow: 0 8px 32px rgba(109, 92, 255, 0.35);
}
.btn-pill.outline {
  background: transparent; color: var(--text);
  border: 1px solid var(--border-strong);
}
.btn-pill.outline:hover {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.28);
  box-shadow: none;
}
.btn-pill--on-dark {
  background: var(--white);
  color: var(--text-inverse);
}
.btn-pill--on-dark:hover {
  background: var(--purple-bright);
  color: var(--white);
}
a.btn-pill,
a.btn-pill:visited {
  color: var(--text-inverse);
}
a.btn-pill.outline,
a.btn-pill.outline:visited {
  color: var(--text);
}
a.btn-pill:hover,
a.btn-pill--on-dark:hover {
  color: var(--white);
}
a.btn-pill.outline:hover {
  color: var(--text);
}
.menu-toggle { display: flex; flex-direction: column; gap: 5px; padding: 8px; }
.menu-toggle span { width: 22px; height: 2px; background: var(--text); }
.mobile-drawer {
  display: none; position: fixed; top: var(--header-h); left: 0; right: 0;
  background: var(--surface); border-bottom: 1px solid var(--border);
  padding: 20px 24px 28px; z-index: 199;
  flex-direction: column; gap: 16px;
  font-size: 0.8rem; font-weight: 600; text-transform: uppercase;
}
.mobile-drawer.open { display: flex; }
@media (min-width: 960px) {
  .nav { display: flex; }
  .menu-toggle { display: none; }
}

/* Brackets */
.bracket {
  display: inline-flex; gap: 0.35em; align-items: center;
  font-size: 0.72rem; font-weight: 600; text-transform: uppercase;
  letter-spacing: 0.06em; color: var(--purple);
  transition: gap 0.25s var(--ease);
}
.bracket:hover { gap: 0.55em; }

/* Hero */
.hero {
  padding: calc(var(--header-h) + 24px) 0 32px;
  background: var(--bg);
}
/* Rounded framed blocks (hero + sections) */
.shell-card {
  position: relative;
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid var(--border-strong);
  background: var(--surface);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.28);
}
.section-panel {
  padding: clamp(32px, 5vw, 56px) clamp(22px, 4vw, 44px);
}
.section-lead--tight { margin-bottom: 0; }

.hero-shell {
  background: var(--hero-fallback);
  min-height: min(72vh, 720px);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transform: scale(1.02);
}
.hero-media__scrim {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(105deg, rgba(9, 9, 11, 0.92) 0%, rgba(9, 9, 11, 0.55) 42%, rgba(9, 9, 11, 0.35) 100%),
    linear-gradient(0deg, rgba(9, 9, 11, 0.75) 0%, transparent 45%);
  pointer-events: none;
}
.hero-content {
  position: relative;
  z-index: 1;
  padding: clamp(32px, 6vw, 56px) clamp(24px, 4vw, 48px) 28px;
}
.hero-content .section-label {
  color: var(--purple-soft);
  text-shadow: 0 1px 24px rgba(0, 0, 0, 0.5);
}
.hero-shell.is-video-off .hero-video {
  opacity: 0;
}
@media (max-width: 767px) {
  .hero-shell { min-height: auto; }
  .hero-media__scrim {
    background:
      linear-gradient(180deg, rgba(9, 9, 11, 0.88) 0%, rgba(9, 9, 11, 0.72) 100%);
  }
}
@media (prefers-reduced-motion: reduce) {
  .hero-video { display: none; }
}
.hero-title {
  font-size: clamp(2.75rem, 9vw, 5.5rem);
  font-weight: 700; line-height: 0.95; letter-spacing: -0.04em;
  max-width: 14ch;
  margin-bottom: 32px;
  text-shadow: 0 2px 40px rgba(0, 0, 0, 0.65);
}
.hero-title .line { display: block; overflow: hidden; }
.hero-title .line-inner {
  display: block;
  transform: translateY(110%);
  animation: hero-in 1s var(--ease) forwards;
}
.hero-title .line:nth-child(2) .line-inner { animation-delay: 0.08s; }
.hero-title .line:nth-child(3) .line-inner { animation-delay: 0.16s; }
@keyframes hero-in { to { transform: translateY(0); } }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 48px; }

/* Marquee */
.marquee-zone { padding: 8px 0 40px; overflow: hidden; }
.marquee-row {
  display: flex; width: max-content;
  animation: marquee 45s linear infinite;
}
.marquee-row.rev { animation-direction: reverse; animation-duration: 55s; }
.marquee-item {
  flex-shrink: 0;
  padding: 10px 28px;
  font-size: 0.7rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.14em;
  color: var(--grey);
  white-space: nowrap;
}
.marquee-item::after { content: '·'; margin-left: 28px; color: var(--purple); }
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* Sections */
.section { padding: 20px 0; }
.section:first-of-type { padding-top: 0; }
.section-label {
  font-size: 0.7rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--purple); margin-bottom: 16px;
}
.section-title {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700; letter-spacing: -0.03em;
  line-height: 1.05; margin-bottom: 20px;
  max-width: 18ch;
}
.section-lead {
  font-size: 1.05rem; color: var(--muted);
  max-width: 42em; margin-bottom: 40px;
}

/* Solution panels */
.solutions-stack { display: flex; flex-direction: column; gap: 12px; }
.solution-panel {
  border-radius: 20px; overflow: hidden;
  background: var(--surface-2); color: var(--text);
  border: 1px solid var(--border-strong);
  min-height: 88px;
  transition: min-height 0.55s var(--ease);
  position: relative;
}
.solution-panel.is-open { min-height: 320px; }
.solution-panel__bg {
  position: absolute; inset: 0;
  background: var(--surface-2);
  opacity: 1;
}
.solution-panel__inner {
  position: relative; z-index: 1;
  padding: 28px 32px;
}
.solution-panel__head {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 16px;
  cursor: pointer;
}
.solution-panel__head h3 {
  font-size: clamp(1.35rem, 3vw, 2.25rem);
  font-weight: 600; line-height: 1.1; letter-spacing: -0.02em;
}
.solution-panel__icon {
  width: 28px; height: 28px; flex-shrink: 0;
  transition: transform 0.4s var(--ease);
}
.solution-panel.is-open .solution-panel__icon { transform: rotate(45deg); }
.solution-panel__tags {
  display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px;
}
.tag {
  font-size: 0.65rem; font-weight: 500;
  text-transform: uppercase; letter-spacing: 0.06em;
  padding: 6px 12px; border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.25);
}
.solution-panel__body {
  max-height: 0; overflow: hidden; opacity: 0;
  transition: max-height 0.55s var(--ease), opacity 0.4s, margin 0.4s;
}
.solution-panel.is-open .solution-panel__body {
  max-height: 240px; opacity: 1; margin-top: 20px;
}
.solution-panel__body p { color: rgba(255,255,255,0.75); font-size: 0.92rem; max-width: 36em; }
.solution-panel__body ul {
  list-style: none; margin-top: 12px;
  font-size: 0.85rem; color: rgba(255,255,255,0.65);
}
.solution-panel__body li { padding: 4px 0; }
.solution-panel__body li::before { content: '— '; color: var(--purple-soft); }

/* Services swiper */
.services-block { position: relative; }
.services-swiper { overflow: visible; padding-bottom: 8px; }
.services-swiper .swiper-slide {
  width: min(100%, 380px);
  height: auto;
  opacity: 0.35;
  transform: scale(0.94);
  transition: opacity 0.4s, transform 0.4s var(--ease);
}
.services-swiper .swiper-slide-active {
  opacity: 1; transform: scale(1);
}
.service-card {
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  border-radius: 20px;
  padding: 28px;
  min-height: 220px;
  display: flex; flex-direction: column; gap: 12px;
}
.service-card__num { font-size: 0.7rem; color: var(--grey); }
.service-card h3 { font-size: 1.15rem; font-weight: 600; letter-spacing: -0.02em; }
.service-card p { font-size: 0.88rem; color: var(--muted); }
.swiper-nav {
  display: flex; gap: 12px; margin-top: 24px;
}
.swiper-nav button {
  width: 56px; height: 36px; border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--text);
  display: flex; align-items: center; justify-content: center;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
}
.swiper-nav button:hover:not(:disabled) {
  background: var(--purple); color: var(--white); border-color: var(--purple);
}
.swiper-nav button:disabled,
.swiper-nav button.swiper-button-disabled {
  color: var(--muted);
  opacity: 0.4;
  cursor: default;
}

/* Industries */
.industry-grid {
  display: grid; gap: 12px;
}
@media (min-width: 768px) { .industry-grid { grid-template-columns: 1fr 1fr; } }
.industry-cell {
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  border-radius: 20px;
  padding: 28px;
}
.industry-cell h4 {
  font-size: 1rem; margin-bottom: 10px;
  display: flex; gap: 10px; align-items: baseline;
}
.industry-cell h4 span { font-size: 0.72rem; color: var(--grey); }
.industry-cell p { font-size: 0.88rem; color: var(--muted); }

/* Cases swiper */
.cases-swiper--inset { margin-top: 32px; }
.case-card {
  background: var(--surface-2); color: var(--text);
  border: 1px solid var(--border-strong);
  border-radius: 20px; padding: 32px;
  min-height: 200px;
  display: flex; flex-direction: column; justify-content: flex-end;
}
.case-card .tag { margin-bottom: 12px; display: inline-block; }

/* About */
.about-grid {
  display: grid; gap: 40px; align-items: center;
}
.section-panel.about-grid { display: grid; }
@media (min-width: 900px) {
  .about-grid { grid-template-columns: 1fr 1fr; }
}
.about-visual {
  aspect-ratio: 1; border-radius: 20px;
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  overflow: hidden;
}
.about-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
.stats { display: flex; flex-wrap: wrap; gap: 32px; margin-top: 28px; }
.stat strong {
  display: block; font-size: 2rem; font-weight: 700;
  color: var(--purple); letter-spacing: -0.03em;
}
.stat span { font-size: 0.82rem; color: var(--muted); }

/* Contact */
.contact-band {
  background: var(--surface);
  color: var(--text);
  padding: clamp(36px, 5vw, 52px) clamp(28px, 4vw, 44px);
  display: grid; gap: 28px;
}
@media (min-width: 768px) {
  .contact-band { grid-template-columns: 1fr auto; align-items: end; }
}
.contact-band .section-label { color: var(--purple-soft); }
.contact-band .section-title { color: var(--text); max-width: none; }
.contact-band__lead { opacity: 0.82; max-width: 36em; }
.contact-links a {
  color: var(--text);
  opacity: 0.9;
}
.contact-links a:hover {
  opacity: 1;
  text-decoration: underline;
}
.contact-band .btn-pill {
  opacity: 1;
  text-decoration: none;
}
.contact-links { display: flex; flex-direction: column; gap: 8px; margin-top: 16px; }

/* Footer */
.site-footer {
  padding: 20px 0 40px;
  background: var(--bg);
  font-size: 0.85rem; color: var(--muted);
}
.footer-panel {
  padding: clamp(36px, 5vw, 52px) clamp(28px, 4vw, 44px) 28px;
}
.footer-grid {
  display: grid; gap: 32px; margin-bottom: 32px;
}
@media (min-width: 800px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; } }
.footer-grid h5 {
  font-size: 0.68rem; text-transform: uppercase;
  letter-spacing: 0.1em; color: var(--grey); margin-bottom: 12px;
}
.footer-grid ul { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.footer-bottom {
  display: flex; flex-wrap: wrap; gap: 12px 20px; justify-content: space-between;
  padding-top: 20px; border-top: 1px solid var(--border);
  font-size: 0.78rem;
  color: var(--muted);
}
.footer-legal { flex: 1 1 100%; max-width: 42em; line-height: 1.5; }
@media (min-width: 800px) {
  .footer-legal { flex: 1 1 auto; text-align: center; }
}

/* Scroll reveal */
.reveal {
  opacity: 0; transform: translateY(32px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}
.reveal.is-visible { opacity: 1; transform: none; }

/* Custom cursor dot on desktop */
@media (min-width: 960px) and (pointer: fine) {
  .cursor-dot {
    position: fixed; width: 8px; height: 8px; border-radius: 50%;
    background: var(--purple); pointer-events: none; z-index: 10000;
    transform: translate(-50%, -50%);
    transition: width 0.2s, height 0.2s, opacity 0.2s;
    opacity: 0;
  }
  .cursor-dot.is-on { opacity: 1; }
  .cursor-dot.is-big { width: 40px; height: 40px; opacity: 0.15; }
}
