@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url('fonts/Inter-latin.woff2') format('woff2');
}

@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400 500;
  font-display: swap;
  src: url('fonts/JetBrainsMono-latin.woff2') format('woff2');
}

  * { margin: 0; padding: 0; box-sizing: border-box; }
  html { scroll-behavior: smooth; overflow-x: clip; }

  body {
    background: #030308;
    color: #e2e4f0;
    font-family: 'Inter', sans-serif;
    overflow-x: hidden;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
  }

  .site-main { flex: 1; }

  /* ═══════════════════════════════════════
     CANVAS
     ═══════════════════════════════════════ */
  canvas#grid {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: 0;
  }

  /* ═══════════════════════════════════════
     ATMOSPHERIC LAYERS
     ═══════════════════════════════════════ */
  .glow-orb {
    position: fixed;
    border-radius: 50%;
    filter: blur(100px);
    z-index: 1;
    pointer-events: none;
  }
  .glow-orb.purple-1 {
    width: 600px; height: 600px;
    top: -5%; right: 5%;
    background: rgba(124, 58, 237, 0.14);
    animation: orb-drift-1 22s ease-in-out infinite;
  }
  .glow-orb.cyan-1 {
    width: 500px; height: 500px;
    bottom: 5%; left: 10%;
    background: rgba(6, 182, 212, 0.09);
    animation: orb-drift-2 28s ease-in-out infinite;
  }
  .glow-orb.purple-2 {
    width: 450px; height: 450px;
    top: 40%; left: 30%;
    background: rgba(91, 33, 182, 0.07);
    animation: orb-drift-3 18s ease-in-out infinite;
  }
  .glow-orb.blue-1 {
    width: 350px; height: 350px;
    top: 10%; left: 50%;
    background: rgba(59, 130, 246, 0.06);
    animation: orb-drift-1 24s ease-in-out infinite reverse;
  }

  @keyframes orb-drift-1 {
    0%, 100% { transform: translate(0, 0); }
    33% { transform: translate(-40px, 25px); }
    66% { transform: translate(25px, -20px); }
  }
  @keyframes orb-drift-2 {
    0%, 100% { transform: translate(0, 0); }
    33% { transform: translate(30px, -25px); }
    66% { transform: translate(-20px, 30px); }
  }
  @keyframes orb-drift-3 {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(-25px, -25px); }
  }

  .scanline {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: 2;
    pointer-events: none;
    background: repeating-linear-gradient(
      0deg, transparent, transparent 2px,
      rgba(124, 58, 237, 0.006) 2px, rgba(124, 58, 237, 0.006) 4px
    );
  }

  .top-glow {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: 350px;
    z-index: 2;
    pointer-events: none;
    background: linear-gradient(
      to bottom,
      rgba(124, 58, 237, 0.12) 0%,
      rgba(124, 58, 237, 0.06) 30%,
      rgba(124, 58, 237, 0.02) 60%,
      transparent 100%
    );
  }

  /* ═══════════════════════════════════════
     SPINE - continuous vertical connector
     ═══════════════════════════════════════ */
  .spine {
    position: fixed;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 1px;
    z-index: 3;
    pointer-events: none;
    background: linear-gradient(
      to bottom,
      transparent 0%,
      transparent 12%,
      rgba(124, 58, 237, 0.08) 15%,
      rgba(124, 58, 237, 0.12) 30%,
      rgba(167, 139, 250, 0.1) 50%,
      rgba(34, 211, 238, 0.08) 70%,
      rgba(124, 58, 237, 0.06) 85%,
      transparent 95%
    );
  }

  /* ═══════════════════════════════════════
     SCROLL REVEAL
     ═══════════════════════════════════════ */
  .motion-ready .reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s ease, transform 0.7s ease;
  }
  .motion-ready .reveal.visible {
    opacity: 1;
    transform: translateY(0);
  }
  .reveal-delay-1 { transition-delay: 0.1s; }

  /* ═══════════════════════════════════════
     HEADER
     ═══════════════════════════════════════ */
  .site-header {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 100;
    padding: 1.5rem 4vw;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    border-bottom: 1px solid rgba(124, 58, 237, 0.1);
    background: rgba(3, 3, 8, 0.5);
    backdrop-filter: blur(16px);
  }

  .site-header .logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
  }

  .site-header .logo .name {
    font-size: 1rem;
    font-weight: 600;
    color: rgba(226, 228, 240, 0.9);
  }

  .site-header .logo .separator {
    width: 1px;
    height: 1rem;
    background: rgba(124, 58, 237, 0.3);
  }

  .site-header .logo .domain {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.82rem;
    font-weight: 500;
    color: rgba(167, 139, 250, 0.6);
    letter-spacing: 0.04em;
  }

  .site-header .logo .cursor {
    display: inline-block;
    width: 2px;
    height: 1em;
    background: #7c3aed;
    margin-left: 2px;
    vertical-align: text-bottom;
    animation: blink 1s step-end infinite;
  }

  @keyframes blink { 50% { opacity: 0; } }

  .site-header nav {
    display: flex;
    gap: 2rem;
  }

  .site-header nav a,
  .site-header nav .nav-coming-soon {
    color: rgba(226, 228, 240, 0.7);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    transition: color 0.3s ease;
  }

  .site-header nav a::before,
  .site-header nav .nav-coming-soon::before {
    content: '//';
    color: rgba(167, 139, 250, 0.65);
    margin-right: 0.3em;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.8rem;
  }

  .site-header nav a:hover,
  .site-header nav a:focus-visible {
    color: #a78bfa;
  }

  .site-header nav a:focus-visible {
    outline: 2px solid #22d3ee;
    outline-offset: 4px;
  }

  .site-header nav .nav-coming-soon {
    color: rgba(226, 228, 240, 0.5);
    cursor: default;
  }

  .nav-coming-soon small {
    display: block;
    margin-left: 1.7em;
    color: #a78bfa;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.65rem;
    letter-spacing: 0.02em;
    text-transform: none;
  }

  @media (max-width: 768px) {
    .site-header {
      padding: 1.1rem 5vw;
      flex-direction: column;
      align-items: flex-start;
      gap: 0.8rem;
    }
    .site-header nav { flex-wrap: wrap; gap: 0.6rem 1.5rem; }
    .site-header nav a,
    .site-header nav .nav-coming-soon { font-size: 0.75rem; }
  }

  /* ═══════════════════════════════════════
     OPENING
     ═══════════════════════════════════════ */
  #opening {
    position: relative;
    z-index: 5;
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 5rem calc(4vw - 4px) 0.5rem 2vw;
  }

  .opening-inner {
    display: flex;
    align-items: center;
    gap: clamp(3.9rem, 5.8vw, 4.5rem);
    max-width: 1160px;
    width: 100%;
    margin: 0 auto;
  }

  .opening-content {
    flex: 1;
    min-width: 0;
  }

  .status-bar {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.6rem;
  }

  .status-dot {
    width: 7px; height: 7px;
    border-radius: 50%;
    background: #22d3ee;
    box-shadow: 0 0 12px rgba(34, 211, 238, 0.6);
    animation: pulse-dot 2s ease-in-out infinite;
  }

  @keyframes pulse-dot {
    0%, 100% { box-shadow: 0 0 12px rgba(34, 211, 238, 0.5); }
    50% { box-shadow: 0 0 24px rgba(34, 211, 238, 0.9); }
  }

  .status-text {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.8rem;
    color: rgba(34, 211, 238, 0.65);
    letter-spacing: 0.04em;
  }

  .status-place {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    vertical-align: middle;
    white-space: nowrap;
  }

  .status-place svg {
    display: block;
    flex-shrink: 0;
    width: 0.9rem;
    height: 0.9rem;
  }

  .status-place .ireland-flag {
    width: 1rem;
    height: 0.68rem;
    border: 1px solid rgba(226, 228, 240, 0.35);
  }

  h1 {
    font-size: clamp(2.5rem, 4vw, 3.5rem);
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 0.4rem;
    letter-spacing: -0.02em;
  }

  h1 .line1 {
    color: rgba(226, 228, 240, 0.95);
  }

  .opening-statement {
    font-size: clamp(1.15rem, 1.7vw, 1.5rem);
    font-weight: 600;
    line-height: 1.4;
    background: linear-gradient(90deg, #7c3aed, #a78bfa, #22d3ee);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
  }

  .social-links {
    display: flex;
    flex-wrap: wrap;
    gap: 1.25rem;
    margin-top: 0.6rem;
  }

  .social-links a {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #a78bfa;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.82rem;
    text-decoration: underline;
    text-decoration-color: rgba(167, 139, 250, 0.5);
    text-underline-offset: 0.3em;
  }

  .social-links svg,
  .social-icon-linkedin {
    width: 1.15rem;
    height: 1.15rem;
    flex-shrink: 0;
  }

  .social-links svg { fill: currentColor; }

  .social-icon-linkedin {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 2px;
    background: #a78bfa;
    color: #030308;
    font-family: 'Inter', sans-serif;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: -0.08em;
  }

  .social-links a:hover,
  .social-links a:focus-visible {
    color: #22d3ee;
  }

  .social-links a:hover .social-icon-linkedin,
  .social-links a:focus-visible .social-icon-linkedin {
    background: #22d3ee;
  }

  .opening-prose {
    margin-top: 0.8rem;
  }

  .opening-prose p {
    font-size: clamp(0.87rem, 1.18vw, 0.94rem);
    line-height: 1.5;
    color: rgba(226, 228, 240, 0.82);
    margin-bottom: 0.7rem;
  }

  .opening-prose p:last-child { margin-bottom: 0; }

  .opening-prose a,
  .journey-entry a {
    color: inherit;
    text-decoration: underline;
    text-decoration-color: rgba(167, 139, 250, 0.6);
    text-underline-offset: 0.18em;
  }

  .opening-prose a:hover,
  .opening-prose a:focus-visible,
  .journey-entry a:hover,
  .journey-entry a:focus-visible {
    color: #22d3ee;
    text-decoration-color: currentColor;
  }

  /* ═══════════════════════════════════════
     PHOTO
     ═══════════════════════════════════════ */
  .opening-photo-wrap {
    flex-shrink: 0;
    position: relative;
    width: clamp(330px, 36vw, 430px);
    aspect-ratio: 1;
    scale: 1.2;
  }

  .opening-photo-ring {
    position: absolute;
    inset: -3px;
    border-radius: 50%;
    overflow: hidden;
    z-index: 0;
  }

  .opening-photo-ring::before {
    content: '';
    position: absolute;
    inset: -50%;
    background: conic-gradient(
      from 220deg,
      rgba(124, 58, 237, 0.55),
      rgba(167, 139, 250, 0.35),
      rgba(34, 211, 238, 0.45),
      rgba(6, 182, 212, 0.25),
      rgba(124, 58, 237, 0.55)
    );
    animation: ring-rotate 12s linear infinite;
  }

  @keyframes ring-rotate { to { transform: rotate(360deg); } }

  .opening-photo-ring::after {
    content: '';
    position: absolute;
    inset: 2px;
    border-radius: 50%;
    background: #030308;
  }

  .opening-photo {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    overflow: hidden;
  }

  .opening-photo img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: contrast(1.04) brightness(1.02);
  }

  .opening-photo-glow {
    position: absolute;
    inset: -60px;
    border-radius: 50%;
    background: radial-gradient(
      circle,
      rgba(124, 58, 237, 0.12) 0%,
      rgba(124, 58, 237, 0.04) 40%,
      transparent 70%
    );
    z-index: -1;
    pointer-events: none;
  }

  /* ═══════════════════════════════════════
     JOURNEY
     ═══════════════════════════════════════ */
  .journey {
    position: relative;
    z-index: 5;
    padding: 4rem 6vw 7rem;
    scroll-margin-top: 6rem;
  }

  .journey-inner {
    max-width: 1150px;
    margin: 0 auto;
  }

  .journey h2 {
    font-size: clamp(1.7rem, 2.6vw, 2.4rem);
    font-weight: 600;
    color: rgba(226, 228, 240, 0.95);
    margin-bottom: 4rem;
  }

  .journey-items {
    position: relative;
    list-style: none;
  }

  .journey-items::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    width: 1px;
    transform: translateX(-50%);
    background: linear-gradient(to bottom, rgba(34, 211, 238, 0.6), rgba(167, 139, 250, 0.45), rgba(124, 58, 237, 0.12));
  }

  .journey-item {
    --marker-color: #a78bfa;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 136px minmax(0, 1fr);
    align-items: start;
    padding-bottom: 4rem;
  }

  .journey-item:nth-child(odd) { --marker-color: #22d3ee; }
  .journey-item:last-child { padding-bottom: 0; }

  .journey-marker {
    grid-column: 2;
    grid-row: 1;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.65rem;
  }

  .journey-date {
    padding: 0.3rem 0.6rem;
    border: 1px solid rgba(167, 139, 250, 0.2);
    border-radius: 100px;
    background: #030308;
    color: var(--marker-color);
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.74rem;
    white-space: nowrap;
  }

  .journey-dot {
    width: 11px;
    height: 11px;
    flex-shrink: 0;
    border: 2px solid var(--marker-color);
    border-radius: 50%;
    background: #030308;
    box-shadow: 0 0 16px var(--marker-color);
  }

  .journey-entry {
    position: relative;
    grid-row: 1;
    padding: 0.75rem 1.5rem 1rem;
    border-left: 1px solid rgba(167, 139, 250, 0.25);
    background: linear-gradient(90deg, rgba(124, 58, 237, 0.055), transparent 85%);
  }

  .journey-entry::before {
    content: '';
    position: absolute;
    top: 2.75rem;
    width: 68px;
    height: 1px;
    background: rgba(167, 139, 250, 0.3);
  }

  .journey-item.left .journey-entry { grid-column: 1; }
  .journey-item.left .journey-entry::before { right: -68px; }
  .journey-item.right .journey-entry { grid-column: 3; }
  .journey-item.right .journey-entry::before { left: -68px; }
  .journey-entry h3 {
    font-size: 1.25rem;
    font-weight: 600;
    line-height: 1.35;
    color: rgba(226, 228, 240, 0.95);
    margin-bottom: 0.9rem;
  }

  .journey-entry p {
    font-size: 0.98rem;
    line-height: 1.8;
    color: rgba(226, 228, 240, 0.78);
    margin-bottom: 1.1rem;
  }

  .journey-entry p:last-child,
  .journey-entry h3:last-child { margin-bottom: 0; }

  /* ═══════════════════════════════════════
     FOOTER
     ═══════════════════════════════════════ */
  .site-footer {
    position: relative;
    z-index: 5;
    padding: 3rem 6vw;
    border-top: 1px solid rgba(124, 58, 237, 0.08);
  }

  .footer-inner {
    max-width: 840px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 2rem;
  }

  .footer-left,
  .footer-right {
    display: flex;
    flex-direction: column;
  }

  .footer-left { gap: 0.5rem; }
  .footer-right {
    align-items: flex-end;
    gap: 0.8rem;
  }

  .footer-name {
    font-size: 0.9rem;
    font-weight: 500;
    color: rgba(226, 228, 240, 0.5);
  }

  .footer-detail {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.7rem;
    color: rgba(226, 228, 240, 0.35);
    letter-spacing: 0.04em;
  }

  .footer-links {
    display: flex;
    gap: 2rem;
  }

  .footer-links a {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.74rem;
    color: rgba(226, 228, 240, 0.4);
    text-decoration: none;
    letter-spacing: 0.04em;
    transition: color 0.3s ease;
    position: relative;
  }

  .footer-links a::before {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0; right: 0;
    height: 1px;
    background: rgba(167, 139, 250, 0.4);
    transform: scaleX(0);
    transition: transform 0.3s ease;
  }

  .footer-links a:hover { color: rgba(167, 139, 250, 0.6); }
  .footer-links a:focus-visible { color: rgba(167, 139, 250, 0.8); }

  .footer-links a:hover::before,
  .footer-links a:focus-visible::before {
    transform: scaleX(1);
  }

  .footer-coordinates {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.65rem;
    color: rgba(226, 228, 240, 0.28);
    letter-spacing: 0.04em;
  }

  @media (min-width: 1400px) {
    .opening-inner { max-width: 1280px; }
  }

  @media (min-width: 901px) and (max-height: 767px) {
    .site-footer { padding-top: 2.2rem; padding-bottom: 2.2rem; }
    .status-bar { margin-bottom: 0.6rem; }
    h1 {
      font-size: clamp(2.5rem, 3.4vw, 3rem);
      margin-bottom: 0.4rem;
    }
    .opening-statement {
      font-size: 1.2rem;
      line-height: 1.35;
    }
    .social-links { margin-top: 0.65rem; }
    .opening-prose { margin-top: 0.9rem; }
    .opening-prose p {
      font-size: 0.875rem;
      line-height: 1.43;
      margin-bottom: 0.5rem;
    }
  }

  /* ═══════════════════════════════════════
     RESPONSIVE
     ═══════════════════════════════════════ */
  @media (max-width: 900px) {
    #opening {
      display: block;
      padding: 8rem 6vw 4rem;
    }
    .opening-inner {
      flex-direction: column-reverse;
      text-align: center;
      gap: 4rem;
    }
    .opening-content { max-width: 680px; }
    h1 { font-size: clamp(2.5rem, 4.5vw, 4rem); }
    .opening-statement { font-size: clamp(1.25rem, 3.2vw, 1.85rem); }
    .opening-photo-wrap {
      width: min(300px, 80vw);
    }
    .opening-prose {
      margin-top: 2.5rem;
      text-align: left;
    }
    .opening-prose p {
      font-size: 1.05rem;
      line-height: 1.85;
      margin-bottom: 1.8rem;
    }
    .status-bar { justify-content: center; }
    .social-links { justify-content: center; }

    .journey { padding: 3rem 5vw 5rem; }
    .journey h2 { margin-bottom: 2.5rem; }
    .journey-items::before {
      left: 9px;
      transform: none;
    }
    .journey-item {
      display: block;
      padding: 0 0 3rem 3rem;
    }
    .journey-marker {
      flex-direction: row;
      gap: 0.8rem;
      margin: 0 0 1rem -3rem;
    }
    .journey-dot { order: -1; margin-left: 4px; }
    .journey-entry { padding: 0.75rem 1rem 1rem; }
    .journey-entry::before { display: none; }
  }

  @media (max-width: 768px) {
    #opening { padding: 10rem 5vw 3rem; }
    .journey { scroll-margin-top: 7rem; }
    .status-role { display: block; }
    .status-role-separator { display: none; }
    .site-footer { padding: 1.5rem 5vw; }
    .footer-inner {
      flex-direction: column;
      align-items: flex-start;
      gap: 1rem;
    }

    @media (prefers-reduced-motion: reduce) {
      html { scroll-behavior: auto; }
      *, *::before, *::after { animation: none !important; transition: none !important; }
    }
    .footer-right { align-items: flex-start; }
  }
