/* ================================================================
   PIRBOR — Cybersecurity Consultancy
   Stylesheet
   ================================================================ */

@font-face{
  font-family:'Glacial Indifference';
  src:url('https://cdn.jsdelivr.net/npm/typeface-glacial-indifference@1.1.13/files/glacial-indifference-regular.woff2') format('woff2'),
      url('https://unpkg.com/typeface-glacial-indifference@1.1.13/files/glacial-indifference-regular.woff2') format('woff2'),
      url('https://cdn.jsdelivr.net/npm/typeface-glacial-indifference@1.1.13/files/glacial-indifference-regular.woff') format('woff');
  font-weight:400;
  font-style:normal;
  font-display:swap;
}
@font-face{
  font-family:'Glacial Indifference';
  src:url('https://cdn.jsdelivr.net/npm/typeface-glacial-indifference@1.1.13/files/glacial-indifference-bold.woff2') format('woff2'),
      url('https://unpkg.com/typeface-glacial-indifference@1.1.13/files/glacial-indifference-bold.woff2') format('woff2'),
      url('https://cdn.jsdelivr.net/npm/typeface-glacial-indifference@1.1.13/files/glacial-indifference-bold.woff') format('woff');
  font-weight:700;
  font-style:normal;
  font-display:swap;
}

/* ================================================================
   1. TOKENS — the entire visual system is derived from this table.
   Monochrome discipline: no accent hue. The only graphic device
   permitted is the 1px hairline (--line), used as the sole
   structural ornament throughout the page.
   ================================================================ */
:root{
  /* — surfaces — */
  --white:      #ffffff;
  --black:      #0a0a0a;   /* true black sections, never pure #000 for print/optical reasons */
  --off:        #f5f5f3;   /* institutional grey — hovers, boxed-menu ground, card ground */

  /* — ink — */
  --ink-100:    #0a0a0a;   /* primary text on white */
  --ink-70:     #4a4a4a;   /* secondary text on white */
  --ink-45:     #8a8a8a;   /* tertiary / meta on white */
  --ink-inv-100:#ffffff;   /* primary text on black */
  --ink-inv-70: #b8b8b8;   /* secondary text on black */
  --ink-inv-45: #6e6e6e;   /* tertiary / meta on black */

  /* — line — */
  --line:       rgba(10,10,10,0.12);
  --line-inv:   rgba(255,255,255,0.16);

  /* — type — */
  --f-wordmark: 'Glacial Indifference', 'Century Gothic', Futura, Avenir, sans-serif;
  --f-body:     'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  /* — scale — */
  --step--1:    0.8125rem;   /* 13px — captions, meta, labels */
  --step-0:     1rem;        /* 16px — body */
  --step-1:     1.125rem;    /* 18px — lead body */
  --step-2:     1.5rem;      /* 24px — card titles */
  --step-3:     2.25rem;     /* 36px — section titles */
  --step-4:     3.5rem;      /* 56px — sub-hero */
  --step-5:     clamp(3.2rem, 6.2vw, 6.5rem); /* hero */

  /* — rhythm — */
  --gutter:     clamp(24px, 5vw, 64px);
  --container:  1360px;
  --section-y:  clamp(88px, 11vw, 176px);

  /* — motion — */
  --ease:       cubic-bezier(0.16, 1, 0.3, 1);
  --dur-s:      0.4s;
  --dur-m:      0.8s;
  --dur-l:      1.2s;
}

/* ================================================================
   2. RESET
   ================================================================ */
*,*::before,*::after{ box-sizing:border-box; margin:0; padding:0; }
html{
  scroll-behavior:smooth;
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
  text-rendering:optimizeLegibility;
}
@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; }
}
body{
  font-family:var(--f-body);
  font-weight:400;
  color:var(--ink-100);
  background:var(--white);
  line-height:1.5;
  overflow-x:hidden;
}
img,video{ display:block; max-width:100%; }
a{ color:inherit; text-decoration:none; }
button{ font:inherit; color:inherit; background:none; border:0; cursor:pointer; }
ul{ list-style:none; }
h1,h2,h3,h4{ font-weight:500; line-height:1.1; }
:focus-visible{ outline:2px solid var(--ink-100); outline-offset:4px; }
::selection{ background:var(--ink-100); color:var(--white); }

/* ================================================================
   3. LAYOUT PRIMITIVES
   ================================================================ */
.container{
  width:100%;
  max-width:var(--container);
  margin-inline:auto;
  padding-inline:var(--gutter);
}
.section{ padding-block:var(--section-y); position:relative; }
.section--black{ background:var(--black); color:var(--ink-inv-100); }
.section--off{ background:var(--off); }

/* the signature device: a hairline that draws itself in on reveal.
   used once per section boundary — the single recurring graphic
   motif specified in the design brief. */
.hairline{
  width:100%; height:1px; background:var(--line);
  transform-origin:left center;
}
.section--black .hairline{ background:var(--line-inv); }

.eyebrow{
  font-size:var(--step--1);
  font-weight:500;
  letter-spacing:0.14em;
  text-transform:uppercase;
  color:var(--ink-45);
  display:flex; align-items:center; gap:10px;
}
.section--black .eyebrow{ color:var(--ink-inv-45); }
.eyebrow::before{
  content:''; width:16px; height:1px; background:currentColor; flex:none;
}

/* ================================================================
   4. SCROLL REVEAL — orchestrated, restrained.
   Single mechanism reused everywhere via [data-reveal]; the
   hairline gets its own keyframe (draw), everything else a
   uniform fade/rise. No per-section bespoke effects.
   ================================================================ */
[data-reveal]{
  opacity:0;
  transform:translateY(28px);
  transition:opacity var(--dur-m) var(--ease), transform var(--dur-m) var(--ease);
}
[data-reveal].is-visible{ opacity:1; transform:translateY(0); }
[data-reveal="line"]{ transform:none; transition:none; }
[data-reveal="line"] .hairline{ transform:scaleX(0); transition:transform 1.1s var(--ease); }
[data-reveal="line"].is-visible .hairline{ transform:scaleX(1); }

[data-reveal-group] > *{
  opacity:0; transform:translateY(24px);
  transition:opacity var(--dur-m) var(--ease), transform var(--dur-m) var(--ease);
}
[data-reveal-group].is-visible > *{ opacity:1; transform:translateY(0); }
[data-reveal-group].is-visible > *:nth-child(1){ transition-delay:0.05s; }
[data-reveal-group].is-visible > *:nth-child(2){ transition-delay:0.14s; }
[data-reveal-group].is-visible > *:nth-child(3){ transition-delay:0.23s; }
[data-reveal-group].is-visible > *:nth-child(4){ transition-delay:0.32s; }

@media (prefers-reduced-motion: reduce){
  [data-reveal],[data-reveal-group] > *{ opacity:1; transform:none; }
  [data-reveal="line"] .hairline{ transform:scaleX(1); }
}

/* ================================================================
   5. HEADER + BOXED MEGA MENU
   ================================================================ */
.site-header{
  position:fixed; inset-inline:0; top:0; z-index:100;
  background:rgba(255,255,255,0.88);
  backdrop-filter:blur(14px); -webkit-backdrop-filter:blur(14px);
  border-bottom:1px solid transparent;
  transition:border-color var(--dur-s) var(--ease), background var(--dur-s) var(--ease);
}
.site-header.is-scrolled{ border-bottom-color:var(--line); }
.site-header.is-menu-open{ background:var(--white); border-bottom-color:transparent; }

.header-row{
  display:flex; align-items:center; justify-content:space-between;
  height:84px;
}
.wordmark{
  font-family:var(--f-wordmark);
  font-weight:400;
  font-size:1.5rem;
  letter-spacing:0.01em;
  line-height:1;
  position:relative; z-index:2;
}

.primary-nav{ display:flex; align-items:center; gap:clamp(20px,3vw,44px); }
.nav-trigger{
  font-size:var(--step--1); font-weight:500;
  letter-spacing:0.04em; text-transform:uppercase;
  display:flex; align-items:center; gap:8px;
  padding:8px 0; position:relative;
}
.nav-trigger .chev{
  width:8px; height:8px; border-right:1px solid currentColor; border-bottom:1px solid currentColor;
  transform:rotate(45deg); transition:transform var(--dur-s) var(--ease); margin-top:-4px;
}
.nav-trigger[aria-expanded="true"] .chev{ transform:rotate(225deg); margin-top:4px; }
.nav-trigger::after{
  content:''; position:absolute; left:0; right:0; bottom:0; height:1px; background:var(--ink-100);
  transform:scaleX(0); transform-origin:left; transition:transform var(--dur-s) var(--ease);
}
.nav-trigger:hover::after,.nav-trigger[aria-expanded="true"]::after{ transform:scaleX(1); }

.nav-cta{
  font-size:var(--step--1); font-weight:500; letter-spacing:0.04em; text-transform:uppercase;
  padding:11px 26px; border:1px solid var(--ink-100);
  transition:background var(--dur-s) var(--ease), color var(--dur-s) var(--ease);
}
.nav-cta:hover{ background:var(--ink-100); color:var(--white); }

.menu-toggle{
  display:none; flex-direction:column; gap:5px; width:26px; z-index:2;
}
.menu-toggle span{ height:1px; width:100%; background:var(--ink-100); transition:transform var(--dur-s) var(--ease), opacity var(--dur-s) var(--ease); }

/* — the mega menu itself: "boxed" — a bounded panel inset from
     the viewport edges, not full-bleed, sitting just below the
     header row, four structured columns. — */
.mega{
  position:absolute; top:100%; left:0; right:0;
  padding:0 var(--gutter) 0;
  pointer-events:none;
}
.mega-panel{
  max-width:var(--container);
  margin-inline:auto;
  background:var(--white);
  border:1px solid var(--line);
  box-shadow:0 32px 64px -24px rgba(10,10,10,0.14);
  opacity:0; transform:translateY(-12px);
  transition:opacity var(--dur-s) var(--ease), transform var(--dur-s) var(--ease);
  max-height:0; overflow:hidden;
}
.mega.is-open{ pointer-events:auto; }
.mega.is-open .mega-panel{ opacity:1; transform:translateY(0); max-height:none; overflow:visible; }

.mega-grid{
  display:grid; grid-template-columns:repeat(4,1fr);
}
.mega-col{
  padding:56px 40px;
  border-left:1px solid var(--line);
}
.mega-col:first-child{ border-left:0; }
.mega-col-label{
  font-size:var(--step--1); font-weight:500; letter-spacing:0.1em; text-transform:uppercase;
  color:var(--ink-45); margin-bottom:28px; padding-bottom:16px; border-bottom:1px solid var(--line);
}
.mega-links{ display:flex; flex-direction:column; gap:18px; }
.mega-links a{
  font-size:var(--step-0); font-weight:400;
  display:block; position:relative; width:fit-content;
  transition:color var(--dur-s) var(--ease);
}
.mega-links a span{
  display:block; font-size:var(--step--1); color:var(--ink-45); font-weight:400; margin-top:3px;
}
.mega-links a::after{
  content:''; position:absolute; left:0; right:0; bottom:-3px; height:1px; background:var(--ink-100);
  transform:scaleX(0); transform-origin:left; transition:transform var(--dur-s) var(--ease);
}
.mega-links a:hover::after{ transform:scaleX(1); }

.mega-foot{
  display:flex; align-items:center; justify-content:space-between;
  padding:22px 40px; border-top:1px solid var(--line); background:var(--off);
  font-size:var(--step--1); color:var(--ink-70);
}
.mega-foot a{ font-weight:500; text-decoration:underline; text-underline-offset:3px; }

.backdrop{
  position:fixed; inset:0; background:rgba(10,10,10,0.28);
  opacity:0; pointer-events:none; transition:opacity var(--dur-s) var(--ease); z-index:90;
}
.backdrop.is-open{ opacity:1; pointer-events:auto; }

/* ================================================================
   6. HERO — corporate density: metadata row, scale metrics,
   monumental title.
   ================================================================ */
.hero{
  padding-top:calc(84px + clamp(56px,9vw,120px));
  padding-bottom:clamp(48px,7vw,88px);
}
.hero-meta{
  display:flex; flex-wrap:wrap; align-items:center; gap:clamp(16px,3vw,40px);
  padding-bottom:28px; margin-bottom:44px; border-bottom:1px solid var(--line);
}
.hero-meta-item{
  font-size:var(--step--1); color:var(--ink-70);
  display:flex; flex-direction:column; gap:4px;
  position:relative;
  padding-right:clamp(16px,3vw,40px);
}
.hero-meta-item b{
  font-weight:500; color:var(--ink-100); letter-spacing:0.02em; text-transform:uppercase; font-size:0.72rem;
}
.hero-meta-item:not(:last-child)::after{
  content:''; position:absolute; top:2px; bottom:2px; right:0; width:1px; background:var(--line);
}

.hero-title-row{
  display:flex; align-items:flex-end; justify-content:space-between; gap:40px;
  flex-wrap:wrap;
}
.hero-title{
  font-size:var(--step-5);
  font-weight:500;
  letter-spacing:-0.02em;
  line-height:0.98;
  max-width:15ch;
}
.hero-title em{
  font-style:normal; font-weight:300; color:var(--ink-45); display:block;
}
.hero-side{
  max-width:340px; padding-bottom:0.6em;
  display:flex; flex-direction:column; gap:20px;
}
.hero-side p{ font-size:var(--step-0); color:var(--ink-70); line-height:1.6; }

.hero-metrics{
  margin-top:clamp(56px,7vw,88px);
  display:grid; grid-template-columns:repeat(4,1fr);
  border-top:1px solid var(--line);
}
.metric{
  padding:28px clamp(16px,2vw,32px) 0; border-left:1px solid var(--line);
}
.metric:first-child{ border-left:0; padding-left:0; }
.metric-value{
  font-size:clamp(1.6rem,2.6vw,2.25rem); font-weight:500; letter-spacing:-0.01em; line-height:1;
}
.metric-label{
  margin-top:10px; font-size:var(--step--1); color:var(--ink-45);
  text-transform:uppercase; letter-spacing:0.06em;
}

/* ================================================================
   7. VIDEO SECTION — exact 40% width, centered; "Discover pirbor"
   sits in the white area directly above it.
   ================================================================ */
.video-section{
  padding-block:clamp(48px,7vw,96px) clamp(88px,11vw,160px);
}
.video-label{
  text-align:center;
  font-size:var(--step--1);
  font-weight:500;
  letter-spacing:0.16em;
  text-transform:uppercase;
  color:var(--ink-70);
  margin-bottom:28px;
}
.video-frame{
  width:40%;
  margin-inline:auto;
  aspect-ratio:16/9;
  background:var(--black);
  position:relative;
  overflow:hidden;
}
.video-frame video{
  width:100%; height:100%; object-fit:cover;
}
.video-frame::after{
  content:''; position:absolute; inset:0; box-shadow:inset 0 0 0 1px rgba(255,255,255,0.06);
  pointer-events:none;
}
@media (max-width:900px){
  .video-frame{ width:88%; }
}

/* ================================================================
   8. INTRODUCTION — dense two-column corporate statement.
   ================================================================ */
.intro-grid{
  display:grid; grid-template-columns:1fr 1.5fr; gap:clamp(40px,6vw,120px);
}
.intro-grid .lead{
  font-size:var(--step-2); font-weight:400; letter-spacing:-0.01em; line-height:1.35;
  color:var(--ink-100);
}
.intro-body{ display:flex; flex-direction:column; gap:22px; padding-top:8px; }
.intro-body p{ font-size:var(--step-1); color:var(--ink-70); line-height:1.65; max-width:56ch; }
@media (max-width:860px){
  .intro-grid{ grid-template-columns:1fr; gap:32px; }
}

/* ================================================================
   9. PRACTICE — rich cards, weighted type, high-performance
   transitions on hover.
   ================================================================ */
.section-head{
  display:flex; align-items:flex-end; justify-content:space-between; gap:24px;
  margin-bottom:clamp(48px,6vw,80px); flex-wrap:wrap;
}
.section-title{ font-size:var(--step-3); font-weight:500; letter-spacing:-0.015em; max-width:14ch; }
.section-head .eyebrow{ margin-bottom:18px; }
.section-desc{ max-width:34ch; font-size:var(--step-0); color:var(--ink-45); line-height:1.6; }

.practice-list{
  border-top:1px solid var(--line);
}
.practice-item{
  border-bottom:1px solid var(--line);
  position:relative;
  overflow:hidden;
}
.practice-link{
  display:grid;
  grid-template-columns:64px 1fr 1.4fr 140px;
  align-items:center;
  gap:clamp(16px,3vw,48px);
  padding:clamp(28px,4vw,44px) 0;
  position:relative; z-index:1;
}
.practice-index{
  font-size:var(--step--1); color:var(--ink-45); font-weight:400;
  font-variant-numeric:tabular-nums;
}
.practice-name{
  font-size:clamp(1.5rem,2.6vw,var(--step-3)); font-weight:500; letter-spacing:-0.01em;
  transition:transform var(--dur-m) var(--ease); transform:translateX(0);
}
.practice-desc{
  font-size:var(--step-0); color:var(--ink-70); line-height:1.6; max-width:52ch;
}
.practice-cta{
  justify-self:end; font-size:var(--step--1); font-weight:500; letter-spacing:0.04em; text-transform:uppercase;
  display:flex; align-items:center; gap:8px; white-space:nowrap;
}
.practice-cta .arrow{ transition:transform var(--dur-s) var(--ease); }
.practice-item::before{
  content:''; position:absolute; inset:0; background:var(--black);
  transform:scaleX(0); transform-origin:left; transition:transform var(--dur-l) var(--ease); z-index:0;
}
.practice-item:hover::before{ transform:scaleX(1); }
.practice-item:hover .practice-name,
.practice-item:hover .practice-index,
.practice-item:hover .practice-desc,
.practice-item:hover .practice-cta{ color:var(--white); }
.practice-item:hover .practice-name{ transform:translateX(12px); }
.practice-item:hover .practice-cta .arrow{ transform:translateX(6px); }
.practice-item a{ display:block; }

@media (max-width:860px){
  .practice-link{ grid-template-columns:40px 1fr; row-gap:14px; }
  .practice-desc{ grid-column:1 / -1; }
  .practice-cta{ grid-column:1 / -1; justify-self:start; }
}

/* ================================================================
   10. PROJECTS — image cards, weight, performant hover.
   ================================================================ */
.projects-grid{
  display:grid; grid-template-columns:repeat(2,1fr); gap:1px;
  background:var(--line);
  border:1px solid var(--line);
}
.project-card{
  background:var(--white); position:relative; overflow:hidden;
  aspect-ratio:4/3;
  display:flex; flex-direction:column; justify-content:flex-end;
}
.project-media{
  position:absolute; inset:0; z-index:0;
}
.project-media img{
  width:100%; height:100%; object-fit:cover;
  transform:scale(1.04); transition:transform var(--dur-l) var(--ease), filter var(--dur-l) var(--ease);
  filter:grayscale(100%) contrast(1.05);
}
.project-card:hover .project-media img{ transform:scale(1.12); filter:grayscale(0%) contrast(1.02); }
.project-media::after{
  content:''; position:absolute; inset:0;
  background:linear-gradient(180deg, rgba(10,10,10,0) 40%, rgba(10,10,10,0.82) 100%);
  z-index:1;
}
.project-body{
  position:relative; z-index:2; padding:clamp(28px,4vw,48px);
  color:var(--white);
  display:flex; align-items:flex-end; justify-content:space-between; gap:20px;
}
.project-text .eyebrow{ color:var(--ink-inv-45); margin-bottom:10px; }
.project-name{ font-size:clamp(1.7rem,3vw,2.5rem); font-weight:500; letter-spacing:-0.01em; }
.project-tag{ font-size:var(--step-0); color:var(--ink-inv-70); margin-top:6px; }
.project-visit{
  flex:none; width:52px; height:52px; border:1px solid rgba(255,255,255,0.4); border-radius:50%;
  display:flex; align-items:center; justify-content:center;
  transition:background var(--dur-s) var(--ease), transform var(--dur-s) var(--ease), border-color var(--dur-s) var(--ease);
}
.project-card:hover .project-visit{ background:var(--white); border-color:var(--white); transform:rotate(45deg); }
.project-visit svg{ width:18px; height:18px; }
.project-card:hover .project-visit svg{ stroke:var(--ink-100); }
@media (max-width:760px){
  .projects-grid{ grid-template-columns:1fr; }
}

/* ================================================================
   11. CONTACT — black section, sober close.
   ================================================================ */
.contact-grid{
  display:grid; grid-template-columns:1.3fr 1fr; gap:clamp(40px,6vw,100px);
  align-items:end;
}
.contact-title{
  font-size:var(--step-4); font-weight:500; letter-spacing:-0.02em; line-height:1.05; max-width:11ch;
}
.contact-side{ display:flex; flex-direction:column; gap:28px; }
.contact-side p{ font-size:var(--step-1); color:var(--ink-inv-70); max-width:36ch; line-height:1.6; }
.contact-link{
  display:inline-flex; align-items:center; gap:14px;
  font-size:var(--step-1); font-weight:500;
  padding-bottom:10px; border-bottom:1px solid var(--line-inv); width:fit-content;
  transition:gap var(--dur-s) var(--ease), border-color var(--dur-s) var(--ease);
}
.contact-link:hover{ gap:20px; border-color:var(--ink-inv-100); }
.contact-meta{
  margin-top:clamp(56px,7vw,96px); padding-top:32px; border-top:1px solid var(--line-inv);
  display:flex; flex-wrap:wrap; justify-content:space-between; gap:20px;
  font-size:var(--step--1); color:var(--ink-inv-45); letter-spacing:0.02em;
}
@media (max-width:860px){
  .contact-grid{ grid-template-columns:1fr; }
}

/* ================================================================
   12. FOOTER
   ================================================================ */
.site-footer{
  background:var(--black); color:var(--ink-inv-70);
  padding-block:40px; border-top:1px solid var(--line-inv);
}
.footer-row{
  display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:16px;
  font-size:var(--step--1);
}
.footer-row .wordmark{ font-size:1.1rem; color:var(--ink-inv-100); }
.footer-links{ display:flex; gap:28px; flex-wrap:wrap; }
.footer-links a{ transition:color var(--dur-s) var(--ease); }
.footer-links a:hover{ color:var(--ink-inv-100); }

/* ================================================================
   13. RESPONSIVE — header / mega menu collapse
   ================================================================ */
@media (max-width:960px){
  .primary-nav{
    position:fixed; inset:0; top:84px; background:var(--white);
    flex-direction:column; align-items:flex-start; justify-content:flex-start;
    padding:12px var(--gutter) 40px; gap:0;
    transform:translateX(100%); transition:transform var(--dur-m) var(--ease);
    overflow-y:auto;
  }
  .site-header.is-menu-open .primary-nav{ transform:translateX(0); }
  .primary-nav > a, .primary-nav > .nav-item{ width:100%; border-bottom:1px solid var(--line); }
  .nav-trigger{ width:100%; justify-content:space-between; padding:20px 0; }
  .nav-cta{ margin-top:24px; text-align:center; }
  .menu-toggle{ display:flex; }

  .mega{ position:static; padding:0; }
  .mega-panel{ border:0; box-shadow:none; }
  .mega-grid{ grid-template-columns:1fr; }
  .mega-col{ border-left:0; border-top:1px solid var(--line); padding:32px 0; }
  .mega-col:first-child{ border-top:0; }
  .mega-foot{ padding:20px 0; background:transparent; }

  .hero-metrics{ grid-template-columns:repeat(2,1fr); row-gap:28px; }
  .metric:nth-child(3){ border-left:0; padding-left:0; }
  .intro-grid{ grid-template-columns:1fr; }
}
