/* TechMendra Systems — triptych posters
   Palette from the hex mark: ice paper, cyan tiles, navy tiles. */

:root {
  --paper:       #f7fbfd;
  --snow:        #ffffff;
  --ice:         #d8fcfc;
  --cyan:        #00c0f0;
  --cyan-2:      #00b0f0;
  --sky:         #0094d8;
  --mid:         #0074b0;
  --deep:        #006094;
  --ink:         #184870;
  --navy:        #1c486c;
  --on-dark:     #f4fbff;
  --on-dark-dim: #c5e6f4;
  --line:        #b7d7e6;
  --line-dark:   #2a5c80;
  --ease:        cubic-bezier(.22, .61, .36, 1);
  --header-h:    72px;
  --display:     "Anton", "Noto Sans", system-ui, sans-serif;
  --body:        "Noto Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--ink);
  color: var(--ink);
  font-family: var(--body);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3, .poster-name, .panel-no, .join-n, .industry, .kicker, .brand-name strong {
  font-family: var(--display);
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 1.08;
  margin: 0;
  text-transform: uppercase;
}

h1 { font-size: clamp(1.55rem, 3.4vw, 2.7rem); }
h2 { font-size: clamp(1.7rem, 3.2vw, 2.6rem); }
h3 { font-size: 1.35rem; }

p { margin: 0; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { font: inherit; }

.wrap {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
}

.skip-link {
  position: absolute; left: -999px; top: 0; z-index: 200;
  background: var(--cyan); color: var(--ink); padding: 10px 16px; font-weight: 700;
}
.skip-link:focus { left: 0; }

.kicker {
  font-size: 13px;
  letter-spacing: 0.18em;
  color: var(--sky);
  margin-bottom: 12px;
}
.kicker-on-dark { color: var(--cyan); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 22px;
  border-radius: 2px;
  font-weight: 600;
  font-size: 14px;
  border: 1px solid transparent;
  cursor: pointer;
  letter-spacing: 0.02em;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease),
    background .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease);
}
.btn-primary {
  background: var(--cyan);
  color: var(--ink);
}
.btn-ghost {
  background: transparent;
  color: var(--on-dark);
  border-color: rgba(244, 251, 255, .35);
}

/* Header sits over the posters */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  height: var(--header-h);
  border-bottom: 1px solid transparent;
  transition: background .3s var(--ease), border-color .3s var(--ease), backdrop-filter .3s var(--ease);
}
.site-header.scrolled {
  background: rgba(24, 72, 112, .92);
  backdrop-filter: saturate(140%) blur(12px);
  border-bottom-color: var(--line-dark);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--on-dark);
}
.brand img {
  border-radius: 4px;
  background: var(--snow);
  flex: 0 0 auto;
}
.brand-name {
  display: flex;
  flex-direction: column;
  line-height: 1;
}
.brand-name strong {
  font-size: 18px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.brand-name span {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--on-dark-dim);
  margin-top: 4px;
  font-family: var(--body);
}

.nav {
  display: flex;
  align-items: center;
  gap: 26px;
}
.nav a {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--on-dark-dim);
  transition: color .2s var(--ease);
}
.nav .nav-cta {
  color: var(--on-dark);
  border: 1px solid rgba(0, 192, 240, .7);
  padding: 8px 16px;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: 0;
  cursor: pointer;
  padding: 8px;
}
.nav-toggle span {
  width: 22px;
  height: 2px;
  background: var(--on-dark);
  border-radius: 1px;
  transition: transform .3s var(--ease), opacity .3s var(--ease);
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ===== Triptych: three equal full-height posters ===== */
.triptych {
  position: relative;
  background: var(--ink);
  min-height: 100vh;
  min-height: 100svh;
}
.posters {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 5px;
  padding: 5px;
  min-height: 100vh;
  min-height: 100svh;
}

.rail {
  position: absolute;
  top: 76px;
  left: 18px;
  right: 18px;
  height: 10px;
  z-index: 4;
  pointer-events: none;
}
.rail-bar {
  position: absolute;
  left: 0; right: 0; top: 3px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--cyan), transparent);
  opacity: .55;
}
.loop {
  position: absolute;
  top: 0;
  width: 10px;
  height: 10px;
  border: 2px solid var(--cyan);
  border-radius: 50%;
  background: var(--ink);
}
.l1 { left: 16.6%; }
.l2 { left: 50%; transform: translateX(-50%); }
.l3 { right: 16.6%; }

.poster {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: calc(100vh - 10px);
  min-height: calc(100svh - 10px);
  padding: 88px 22px 168px;
  color: var(--on-dark);
  isolation: isolate;
  transition: transform .35s var(--ease), box-shadow .35s var(--ease), filter .35s var(--ease);
}
.poster-hw { background: var(--ink); }
.poster-sw { background: var(--deep); }
.poster-au { background: var(--mid); }

.poster-hang {
  position: absolute;
  top: 0; left: 50%;
  width: 2px;
  height: 18px;
  background: var(--cyan);
  transform: translateX(-50%);
  opacity: .7;
}
.poster-hang::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -8px;
  width: 10px;
  height: 10px;
  border: 2px solid var(--cyan);
  border-radius: 50%;
  transform: translateX(-50%);
}

.scan {
  position: absolute;
  left: -10%;
  right: -10%;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--cyan), transparent);
  opacity: 0;
  z-index: 2;
  pointer-events: none;
  animation: scan 7.5s ease-in-out infinite;
}
.poster-sw .scan { animation-delay: 2.4s; }
.poster-au .scan { animation-delay: 4.8s; }

@keyframes scan {
  0%   { top: 12%; opacity: 0; }
  8%   { opacity: .85; }
  92%  { opacity: .4; }
  100% { top: 88%; opacity: 0; }
}

.poster-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  position: relative;
  z-index: 3;
}
.panel-no {
  font-size: clamp(2.4rem, 6vw, 4rem);
  color: var(--cyan);
  line-height: .8;
}
.panel-tag {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--on-dark-dim);
}

.poster-name {
  position: absolute;
  left: 18px;
  top: 46%;
  z-index: 3;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  font-size: clamp(3.2rem, 9vh, 6.8rem);
  letter-spacing: 0.06em;
  line-height: .82;
  color: var(--on-dark);
  text-shadow: 0 8px 28px rgba(24, 72, 112, .35);
  pointer-events: none;
}

.poster-motif {
  position: absolute;
  right: -8%;
  top: 22%;
  width: min(280px, 72%);
  opacity: .9;
  z-index: 1;
  pointer-events: none;
}
.hex-field { width: 100%; height: auto; display: block; }

.hx {
  fill: rgba(0, 192, 240, 0.08);
  animation: hexFill 4.8s ease-in-out infinite;
}
.hx.h1 { animation-delay: .0s; }
.hx.h2 { animation-delay: .15s; }
.hx.h3 { animation-delay: .3s; }
.hx.h4 { animation-delay: .45s; }
.hx.h5 { animation-delay: .2s; }
.hx.h6 { animation-delay: .35s; }
.hx.h7 { animation-delay: .5s; }
.hx.h9 { animation-delay: .4s; }
.hx.h12 { animation-delay: .55s; }
.hx.h13 { animation-delay: .25s; }
.hx.h14 { animation-delay: .4s; }
.hx.h15 { animation-delay: .55s; }
.hx.h16 { animation-delay: .7s; }
.hx.h17 { animation-delay: .5s; }
.hx.h18 { animation-delay: .65s; }
.hx.h19 { animation-delay: .8s; }
.hx.h20 { animation-delay: .95s; }

@keyframes hexFill {
  0%, 100% { fill: rgba(0, 192, 240, 0.06); stroke-opacity: .55; }
  50%      { fill: rgba(0, 192, 240, 0.28); stroke-opacity: 1; }
}

.bolt {
  animation: blink 2.8s ease-in-out infinite;
}
.b2 { animation-delay: .9s; }
.b3 { animation-delay: 1.6s; }
@keyframes blink {
  0%, 100% { opacity: .25; }
  50% { opacity: 1; }
}

.bus {
  stroke-dasharray: 8 10;
  animation: dash 12s linear infinite;
}
@keyframes dash { to { stroke-dashoffset: -180; } }

.orbit {
  transform-origin: 90px 90px;
  animation: spin 18s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.poster-copy {
  position: relative;
  z-index: 3;
  max-width: 28ch;
  font-size: 0.98rem;
  color: var(--on-dark-dim);
  margin-left: auto;
}

/* Caption plate across the three posters */
.caption {
  position: absolute;
  left: 5px;
  right: 5px;
  bottom: 5px;
  z-index: 6;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  padding: 28px 28px 24px;
  background: linear-gradient(to top, rgba(24, 72, 112, .94) 0%, rgba(24, 72, 112, .72) 55%, transparent 100%);
  color: var(--on-dark);
  pointer-events: none;
}
.caption a, .caption .btn { pointer-events: auto; }
.industry {
  font-size: 12px;
  letter-spacing: 0.22em;
  color: var(--cyan);
  margin-bottom: 10px;
}
.caption h1 {
  max-width: 18ch;
  color: var(--on-dark);
}
.caption-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding-bottom: 4px;
}

/* About: light paper, navy type */
.about {
  background: var(--paper);
  color: var(--ink);
  padding: 88px 0;
}
.about-grid {
  display: grid;
  grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr);
  gap: 48px 56px;
  align-items: start;
}
.about-copy {
  display: grid;
  gap: 18px;
  font-size: 1.05rem;
  color: var(--navy);
}
.about-copy p + p { color: var(--ink); }

/* Practice */
.practice {
  background: var(--snow);
  color: var(--ink);
  padding: 88px 0 40px;
  border-top: 1px solid var(--line);
}
.practice-head { max-width: 640px; margin-bottom: 36px; }
.practice-head h2 { margin-top: 4px; }
.join-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0;
}
.join {
  display: grid;
  grid-template-columns: 88px 1fr;
  gap: 20px;
  align-items: start;
  padding: 28px 8px;
  border-top: 1px solid var(--line);
  transition: transform .25s var(--ease), background .25s var(--ease);
}
.join:last-child { border-bottom: 1px solid var(--line); }
.join-n {
  font-size: clamp(2rem, 4vw, 2.8rem);
  color: var(--sky);
  line-height: 1;
}
.join h3 { margin-bottom: 8px; }
.join p { color: var(--navy); max-width: 62ch; }

/* Quote: dark band, near-white type */
.quote-band {
  background: var(--ink);
  color: var(--on-dark);
  padding: 88px 0;
}
.quote-band blockquote {
  margin: 0;
  max-width: 18ch;
}
.quote-band p {
  font-family: var(--display);
  font-size: clamp(1.8rem, 4.2vw, 3.2rem);
  line-height: 1.12;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: var(--on-dark);
}
.quote-band cite {
  display: block;
  margin-top: 22px;
  font-style: normal;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--cyan);
}

/* FAQ: light */
.faq {
  background: var(--paper);
  color: var(--ink);
  padding: 88px 0;
}
.faq-grid {
  display: grid;
  grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr);
  gap: 40px 48px;
  align-items: start;
}
.faq-head p:last-child {
  margin-top: 14px;
  color: var(--navy);
}
.faq-list { display: grid; gap: 10px; }
.faq-item {
  background: var(--snow);
  border: 1px solid var(--line);
  overflow: hidden;
  transition: border-color .25s var(--ease), transform .25s var(--ease);
}
.faq-item.open { border-color: var(--sky); }
.faq-q {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: none;
  border: 0;
  cursor: pointer;
  text-align: left;
  color: var(--ink);
  font-family: var(--body);
  font-size: 1.05rem;
  font-weight: 700;
  padding: 20px 22px;
}
.faq-ico {
  position: relative;
  flex: 0 0 auto;
  width: 16px;
  height: 16px;
}
.faq-ico::before, .faq-ico::after {
  content: "";
  position: absolute;
  background: var(--sky);
  border-radius: 2px;
  transition: transform .3s var(--ease), opacity .3s var(--ease);
}
.faq-ico::before { top: 7px; left: 0; width: 16px; height: 2px; }
.faq-ico::after { top: 0; left: 7px; width: 2px; height: 16px; }
.faq-item.open .faq-ico::after { transform: scaleY(0); opacity: 0; }
.faq-a { max-height: 0; overflow: hidden; transition: max-height .35s ease; }
.faq-item.open .faq-a { max-height: 280px; }
.faq-a p {
  color: var(--navy);
  margin: 0;
  padding: 0 22px 20px;
  font-size: .98rem;
}

/* Contact: dark band, near-white type */
.contact {
  background: var(--deep);
  color: var(--on-dark);
  padding: 88px 0;
}
.contact-grid {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 40px;
  align-items: stretch;
}
.contact-copy h2 { margin: 6px 0 12px; color: var(--on-dark); }
.contact-copy p { color: var(--on-dark-dim); }
.mail {
  display: inline-block;
  margin-top: 22px;
  font-family: var(--display);
  font-size: clamp(1.2rem, 2.4vw, 1.7rem);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--on-dark);
  border-bottom: 2px solid var(--cyan);
  word-break: break-all;
  transition: transform .25s var(--ease), color .25s var(--ease);
}
.addr {
  margin-top: 18px;
  color: var(--on-dark-dim);
  font-size: .98rem;
}
.contact-card {
  background: var(--ink);
  color: var(--on-dark);
  padding: 32px;
  border: 1px solid var(--line-dark);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 12px;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease);
}
.contact-card .kicker { color: var(--cyan); }
.contact-card h3 { color: var(--on-dark); }
.contact-card p { color: var(--on-dark-dim); margin-bottom: 8px; }
.contact-card .btn-primary { align-self: flex-start; margin-top: 8px; }

/* Footer: dark, near-white */
.site-footer {
  background: var(--ink);
  color: var(--on-dark);
  padding: 48px 0 28px;
  border-top: 1px solid var(--line-dark);
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 28px;
  flex-wrap: wrap;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--line-dark);
}
.footer-tag {
  color: var(--on-dark-dim);
  margin-top: 12px;
  font-size: .95rem;
  max-width: 42ch;
}
.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 22px;
}
.footer-nav a {
  color: var(--on-dark-dim);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding-top: 18px;
  color: var(--on-dark-dim);
  font-size: 14px;
}

/* Reveal MUST sit before hover transforms */
.js .reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .7s var(--ease), transform .7s var(--ease);
}
.js .reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .scan, .hx, .bolt, .bus, .orbit, .pkt { animation: none !important; }
}

/* Hover AFTER .reveal.in so lift is not overwritten */
@media (hover: hover) and (pointer: fine) {
  .nav a:hover { color: var(--on-dark); }
  .nav .nav-cta:hover {
    background: var(--cyan);
    color: var(--ink);
    transform: translateY(-2px);
  }
  .btn-primary:hover {
    transform: translateY(-3px);
    background: var(--cyan-2);
    box-shadow: 0 14px 28px -12px rgba(0, 192, 240, .55);
  }
  .btn-ghost:hover {
    transform: translateY(-3px);
    border-color: var(--cyan);
    color: var(--cyan);
  }
  .poster.in:hover {
    transform: translateY(-10px);
    box-shadow: 0 22px 48px -18px rgba(0, 0, 0, .45);
    z-index: 5;
  }
  .join:hover {
    transform: translateY(-4px);
    background: var(--paper);
  }
  .faq-q:hover { color: var(--deep); }
  .faq-item:hover { border-color: var(--sky); }
  .contact-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 22px 40px -22px rgba(0, 0, 0, .5);
  }
  .mail:hover {
    color: var(--cyan);
    transform: translateY(-2px);
  }
  .footer-nav a:hover { color: var(--cyan); }
}

/* Tablet: posters still three if possible, tighten type */
@media (max-width: 980px) {
  .caption {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    padding: 24px 20px 20px;
  }
  .caption h1 { max-width: none; }
  .about-grid, .faq-grid, .contact-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }
  .poster-name { font-size: clamp(2.6rem, 8vh, 4.6rem); }
}

/* Mobile ~390px: posters stack full-width */
@media (max-width: 860px) {
  .wrap { padding: 0 20px; }

  .nav-toggle { display: flex; }
  .nav {
    position: fixed;
    inset: var(--header-h) 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--ink);
    border-bottom: 1px solid var(--line-dark);
    padding: 8px 20px 18px;
    transform: translateY(-120%);
    transition: transform .35s var(--ease);
    z-index: 90;
  }
  .nav.open { transform: translateY(0); }
  .nav a {
    color: var(--on-dark);
    padding: 14px 0;
    border-bottom: 1px solid var(--line-dark);
    font-size: 16px;
  }
  .nav .nav-cta {
    margin-top: 12px;
    text-align: center;
    justify-content: center;
    display: inline-flex;
  }

  .triptych { min-height: 0; }
  .posters {
    grid-template-columns: 1fr;
    gap: 8px;
    padding: 8px;
    min-height: 0;
  }
  .rail { display: none; }
  .poster {
    min-height: 100vh;
    min-height: 100svh;
    width: 100%;
    padding: 92px 20px 36px;
  }
  .poster-name {
    position: static;
    writing-mode: horizontal-tb;
    transform: none;
    font-size: clamp(3rem, 14vw, 4.6rem);
    margin: 18px 0 8px;
  }
  .poster-motif {
    position: relative;
    right: auto;
    top: auto;
    width: min(220px, 70%);
    margin: 8px 0 16px auto;
  }
  .poster-copy {
    margin-left: 0;
    max-width: 40ch;
  }
  .caption {
    position: relative;
    left: auto;
    right: auto;
    bottom: auto;
    grid-column: 1;
    background: var(--ink);
    padding: 32px 20px 36px;
    pointer-events: auto;
  }

  .about, .practice, .faq, .contact, .quote-band { padding: 56px 0; }
  .join { grid-template-columns: 64px 1fr; padding: 22px 0; }
  .contact-card { padding: 24px; }
  .footer-inner { padding-bottom: 22px; }
}

@media (max-width: 420px) {
  .brand-name span { display: none; }
  .caption-actions { width: 100%; }
  .caption-actions .btn { flex: 1 1 auto; }
  .panel-no { font-size: 2.2rem; }
}
