/* ==========================================================================
   JAN GERLACH (JANEK.OVH) - MINIMALIST PURE OLED BLACK SHOWCASE
   Aesthetic: OLED Pitch Black, Pure White Typographic Contrast,
   Modern Squircles, Concentric Orbit Physics & Fluid Micro-Interactions.
   ========================================================================== */

:root {
  --bg-black: #000000;
  --bg-surface: #09090b;
  --bg-card: rgba(16, 16, 20, 0.65);
  --bg-card-hover: rgba(26, 26, 32, 0.85);
  --bg-glass: rgba(8, 8, 10, 0.75);
  --bg-pill: rgba(255, 255, 255, 0.06);

  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-medium: rgba(255, 255, 255, 0.16);
  --border-bright: rgba(255, 255, 255, 0.35);

  --text-white: #ffffff;
  --text-gray: #a1a1aa;
  --text-dim: #71717a;
  --text-muted: #52525b;

  --accent-emerald: #10b981;

  /* Squircles */
  --radius-sm: 14px;
  --radius-md: 22px;
  --radius-lg: 32px;
  --radius-xl: 40px;
  --radius-full: 9999px;

  --font-sans: 'Space Grotesk', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  --transition-fast: 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-normal: 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  background-color: var(--bg-black);
  color: var(--text-white);
  overflow-x: hidden;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-black);
  color: var(--text-white);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 6px;
}
::-webkit-scrollbar-track {
  background: var(--bg-black);
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-full);
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.3);
}

/* Ambient Subtle Lighting */
.ambient-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}
.ambient-spotlight {
  position: absolute;
  top: -15%;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 600px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.05) 0%, transparent 65%);
  filter: blur(80px);
}
.ambient-glow-bottom {
  position: absolute;
  bottom: -15%;
  right: 15%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.025) 0%, transparent 60%);
  filter: blur(100px);
}
.dot-matrix-overlay {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.1) 1px, transparent 1px);
  background-size: 40px 40px;
  opacity: 0.25;
}
.flashlight-layer {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.35) 1px, transparent 1.5px);
  background-size: 40px 40px;
  -webkit-mask-image: radial-gradient(300px circle at var(--fx, 50%) var(--fy, 20%), #000 0%, transparent 70%);
  mask-image: radial-gradient(300px circle at var(--fx, 50%) var(--fy, 20%), #000 0%, transparent 70%);
}

/* Hide native system cursor on devices with mouse pointer */
@media (pointer: fine) {
  *, *::before, *::after {
    cursor: none !important;
  }
}

/* ==========================================================================
   HUD TARGET CURSOR (Active Custom Crosshair)
   ========================================================================== */
.hud-cursor {
  position: fixed;
  top: 0;
  left: 0;
  width: 38px;
  height: 38px;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: width 0.28s cubic-bezier(0.16, 1, 0.3, 1),
              height 0.28s cubic-bezier(0.16, 1, 0.3, 1),
              background-color 0.25s ease, border-color 0.25s ease,
              border-radius 0.28s ease, opacity 0.25s ease;
  will-change: transform, width, height;
  mix-blend-mode: difference;
  opacity: 0;
}
.hud-cursor.is-visible { opacity: 1; }

.hud-cursor .cursor-dot {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 4px;
  height: 4px;
  background: #ffffff;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.hud-cursor .corner {
  position: absolute;
  width: 9px;
  height: 9px;
  border: 1.5px solid rgba(255, 255, 255, 0.9);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.2s ease;
}

.hud-cursor .corner-tl { top: 0; left: 0; border-right: 0; border-bottom: 0; border-top-left-radius: 3px; }
.hud-cursor .corner-tr { top: 0; right: 0; border-left: 0; border-bottom: 0; border-top-right-radius: 3px; }
.hud-cursor .corner-bl { bottom: 0; left: 0; border-right: 0; border-top: 0; border-bottom-left-radius: 3px; }
.hud-cursor .corner-br { bottom: 0; right: 0; border-left: 0; border-top: 0; border-bottom-right-radius: 3px; }

.hud-cursor .cursor-label {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #fff;
  white-space: nowrap;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.hud-cursor.is-hovering {
  width: 56px;
  height: 56px;
}
.hud-cursor.is-hovering .corner {
  border-color: #ffffff;
  width: 14px;
  height: 14px;
}
.hud-cursor.is-hovering .cursor-dot {
  transform: translate(-50%, -50%) scale(1.6);
}
/* Stan "snap": pusta ramka z narożników, zero wypełnienia w środku */
.hud-cursor.is-snapping {
  background: transparent;
  border: 0;
  border-radius: 0;
}
/* Ramka lockująca się na elemencie — kursor zostaje wolny */
.snap-frame {
  position: fixed;
  top: 0;
  left: 0;
  width: 0;
  height: 0;
  pointer-events: none;
  z-index: 9998;
  opacity: 0;
  transition: opacity 0.22s ease;
  mix-blend-mode: difference;
}
.snap-frame.is-on { opacity: 1; }
.snap-frame .corner {
  position: absolute;
  width: 14px;
  height: 14px;
  border: 2px solid #ffffff;
  filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.6));
}
.snap-frame .corner-tl { top: -7px; left: -7px; border-right: 0; border-bottom: 0; border-top-left-radius: 4px; }
.snap-frame .corner-tr { top: -7px; right: -7px; border-left: 0; border-bottom: 0; border-top-right-radius: 4px; }
.snap-frame .corner-bl { bottom: -7px; left: -7px; border-right: 0; border-top: 0; border-bottom-left-radius: 4px; }
.snap-frame .corner-br { bottom: -7px; right: -7px; border-left: 0; border-top: 0; border-bottom-right-radius: 4px; }
.hud-cursor.is-snapping .cursor-label { opacity: 0 !important; }

.hud-cursor.is-clicking { opacity: 0.6; }

@media (pointer: coarse) {
  .hud-cursor { display: none !important; }
}

/* ==========================================================================
   NAVBAR — zawsze idealnie na środku
   ========================================================================== */
.header-container {
  position: fixed;
  top: 24px;
  left: 50%;
  transform: translateX(-50%);
  width: min(940px, calc(100% - 40px));
  display: flex;
  justify-content: center;
  z-index: 1000;
  pointer-events: none;
}

.nav-bar {
  pointer-events: auto;
  display: grid;
  grid-template-columns: auto 1fr auto auto;
  align-items: center;
  gap: 20px;
  background: var(--bg-glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 8px 10px 8px 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7);
  max-width: 820px;
  width: 100%;
  transition: border-color var(--transition-fast);
}
.nav-bar:hover {
  border-color: var(--border-medium);
}

/* Toasty (brakowało styli — powiadomienia były niewidoczne) */
.toast-container {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  z-index: 10000;
  pointer-events: none;
}
.toast {
  background: #fff;
  color: #000;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 10px 20px;
  border-radius: var(--radius-full);
  box-shadow: 0 8px 30px rgba(255, 255, 255, 0.25);
  animation: toastIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  white-space: nowrap;
}
@keyframes toastIn {
  from { opacity: 0; transform: translateY(12px) scale(0.95); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text-white);
  font-weight: 700;
  font-size: 1rem;
}
.brand-pill {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #ffffff;
  color: #000000;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.78rem;
}

.nav-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  white-space: nowrap;
}
.nav-link {
  color: var(--text-gray);
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 600;
  padding: 8px 16px;
  border-radius: var(--radius-full);
  transition: all var(--transition-fast);
  white-space: nowrap;
}
.nav-link:hover {
  color: var(--text-white);
  background: var(--bg-pill);
}

.nav-cta {
  background: #ffffff;
  color: #000000;
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 8px 18px;
  border-radius: var(--radius-full);
  transition: all var(--transition-fast);
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 142px;
  text-align: center;
}
.nav-cta:hover {
  transform: translateY(-2px);
  background: #e4e4e7;
  box-shadow: 0 4px 15px rgba(255, 255, 255, 0.2);
}

.lang-switch {
  display: flex;
  align-items: center;
  gap: 2px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 3px;
  background: var(--bg-pill);
  flex-shrink: 0;
}
.lang-switch button {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--text-dim);
  background: transparent;
  border: none;
  border-radius: var(--radius-full);
  padding: 5px 10px;
  transition: all var(--transition-fast);
}
.lang-switch button:hover { color: var(--text-white); }
.lang-switch button.active {
  background: #ffffff;
  color: #000000;
}

/* ==========================================================================
   BUTTONS
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 700;
  padding: 14px 28px;
  border-radius: var(--radius-full);
  text-decoration: none;
  cursor: pointer;
  transition: all var(--transition-normal);
  border: none;
  line-height: 1.2;
}

.btn-primary {
  background: #ffffff;
  color: #000000;
  box-shadow: 0 4px 20px rgba(255, 255, 255, 0.15);
}
.btn-primary:hover {
  transform: translateY(-3px) scale(1.02);
  background: #e4e4e7;
  box-shadow: 0 8px 30px rgba(255, 255, 255, 0.3);
}

.btn-secondary {
  background: var(--bg-card);
  color: var(--text-white);
  border: 1px solid var(--border-medium);
  backdrop-filter: blur(14px);
}
.btn-secondary:hover {
  border-color: #ffffff;
  background: var(--bg-card-hover);
  transform: translateY(-3px);
}

.btn-icon-right svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
  transition: transform var(--transition-fast);
}
.btn:hover .btn-icon-right svg {
  transform: translateX(4px);
}

/* ==========================================================================
   HERO SECTION & ORBITS
   ========================================================================== */
.hero-section {
  min-height: 100vh;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 150px 24px 80px;
  overflow: hidden;
  background: radial-gradient(circle at 50% 45%, rgba(255, 255, 255, 0.035) 0%, transparent 65%);
}

.orbit-system {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 960px;
  height: 960px;
  pointer-events: none;
  z-index: 1;
  opacity: 0.65;
}

.orbit-track {
  position: absolute;
  top: 50%;
  left: 50%;
  border-radius: 50%;
  border: 1px dashed rgba(255, 255, 255, 0.08);
  transform: translate(-50%, -50%);
}

.orbit-track-1 {
  width: 440px;
  height: 440px;
  animation: rotateOrbit 65s linear infinite;
}
.orbit-track-2 {
  width: 760px;
  height: 760px;
  animation: rotateOrbitReverse 110s linear infinite;
}

.orbit-item {
  position: absolute;
  top: 50%;
  left: 50%;
  margin: -22px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-medium);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.6);
}
.orbit-item svg {
  width: 20px;
  height: 20px;
  fill: #ffffff;
}

.orbit-track-1 .orbit-item { animation: counterRotateOrbit 65s linear infinite; }
.orbit-track-2 .orbit-item { animation: counterRotateOrbitReverse 110s linear infinite; }

@keyframes rotateOrbit {
  from { transform: translate(-50%, -50%) rotate(0deg); }
  to { transform: translate(-50%, -50%) rotate(360deg); }
}
@keyframes rotateOrbitReverse {
  from { transform: translate(-50%, -50%) rotate(360deg); }
  to { transform: translate(-50%, -50%) rotate(0deg); }
}
@keyframes counterRotateOrbit {
  from { transform: rotate(0deg); }
  to { transform: rotate(-360deg); }
}
@keyframes counterRotateOrbitReverse {
  from { transform: rotate(-360deg); }
  to { transform: rotate(0deg); }
}

.hero-content {
  position: relative;
  z-index: 10;
  max-width: 860px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  padding: 7px 18px;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--text-white);
  text-transform: uppercase;
  backdrop-filter: blur(12px);
}
.pulse-dot {
  position: relative;
  display: inline-block;
  width: 6px;
  height: 6px;
  background: var(--accent-emerald);
  border-radius: 50%;
}
.pulse-dot::after {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  background: var(--accent-emerald);
  opacity: 0.6;
  animation: ping 2s cubic-bezier(0, 0, 0.2, 1) infinite;
}

@keyframes ping {
  75%, 100% {
    transform: scale(2.4);
    opacity: 0;
  }
}

.hero-subtitle {
  font-size: clamp(1.3rem, 2.8vw, 2.2rem);
  font-weight: 500;
  letter-spacing: -0.03em;
  color: var(--text-gray);
}
.hero-subtitle strong {
  color: var(--text-white);
  font-weight: 800;
}

.hero-title-massive {
  font-size: clamp(3.8rem, 12vw, 9.5rem);
  font-weight: 900;
  letter-spacing: -0.06em;
  line-height: 0.85;
  text-transform: uppercase;
  color: #ffffff;
  user-select: none;
}

.hero-bio {
  font-size: clamp(1rem, 1.8vw, 1.2rem);
  color: var(--text-gray);
  max-width: 680px;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 10px;
}

/* ==========================================================================
   SECTION COMMON
   ========================================================================== */
.section {
  position: relative;
  z-index: 10;
  padding: 100px 24px;
  max-width: 1100px;
  margin: 0 auto;
}

.section-header {
  margin-bottom: 50px;
}

.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--text-dim);
  margin-bottom: 12px;
}
.section-tag::before {
  content: '';
  display: inline-block;
  width: 16px;
  height: 1.5px;
  background: #ffffff;
}

.section-title {
  font-size: clamp(2.4rem, 4.5vw, 3.6rem);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: -0.04em;
  line-height: 1;
  color: #ffffff;
}
.section-title .dim {
  color: var(--text-muted);
}

.section-description {
  font-size: 1.05rem;
  color: var(--text-gray);
  margin-top: 12px;
}

/* ==========================================================================
   FOCUS / CO ROBIĘ (3 ORGANIC SQUIRCLES)
   ========================================================================== */
.focus-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.focus-card {
  background: var(--bg-card);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 38px 30px;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  transition: all var(--transition-normal);
}
.focus-card:hover {
  transform: translateY(-6px);
  border-color: var(--border-bright);
  background: var(--bg-card-hover);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.8);
}

.focus-number {
  position: absolute;
  top: 24px;
  right: 28px;
  font-size: 1.1rem;
  font-weight: 800;
  font-family: var(--font-mono);
  color: var(--text-muted);
}

.focus-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  background: var(--bg-pill);
  border: 1px solid var(--border-medium);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  transition: all var(--transition-fast);
}
.focus-card:hover .focus-icon {
  background: #ffffff;
  border-color: #ffffff;
}
.focus-icon svg {
  width: 24px;
  height: 24px;
  fill: #ffffff;
  transition: fill var(--transition-fast);
}
.focus-card:hover .focus-icon svg {
  fill: #000000;
}

.focus-title {
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #ffffff;
  margin-bottom: 12px;
}

.focus-desc {
  font-size: 0.94rem;
  color: var(--text-gray);
  line-height: 1.65;
  margin-bottom: 24px;
}

.focus-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
}
.focus-pills span {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: var(--radius-full);
  background: var(--bg-pill);
  border: 1px solid var(--border-subtle);
  color: var(--text-gray);
}

/* ==========================================================================
   SELECTED PROJECTS (CLEAN STRIPS)
   ========================================================================== */
.projects-container {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.project-strip {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 28px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  transition: all var(--transition-normal);
}
.project-strip:hover {
  border-color: var(--border-bright);
  background: var(--bg-card-hover);
  transform: translateX(6px);
}

.project-strip-left {
  display: flex;
  align-items: center;
  gap: 24px;
}
.project-num {
  font-family: var(--font-mono);
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text-muted);
}
.project-strip-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.02em;
  margin-bottom: 4px;
}
.project-strip-desc {
  font-size: 0.92rem;
  color: var(--text-gray);
  max-width: 580px;
}

.project-strip-tags {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}
.project-strip-tags span {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: var(--radius-full);
  background: var(--bg-pill);
  border: 1px solid var(--border-subtle);
  color: var(--text-gray);
}

/* ==========================================================================
   CONTACT SECTION
   ========================================================================== */
.contact-box {
  position: relative;
  overflow: hidden;
  background: var(--bg-card);
  backdrop-filter: blur(24px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 56px 48px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 32px;
  transition: border-color var(--transition-fast);
}
.contact-box:hover {
  border-color: var(--border-medium);
}

.contact-headline {
  font-size: clamp(2.2rem, 4.5vw, 3.4rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  color: #ffffff;
  margin-top: 8px;
}
.contact-sub {
  font-size: 1.05rem;
  color: var(--text-gray);
  max-width: 520px;
  margin-top: 8px;
}

.contact-direct-actions {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  justify-content: center;
  width: 100%;
}

.email-badge-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 20px 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  min-width: 260px;
  transition: all var(--transition-fast);
}
.email-badge-card:hover {
  border-color: var(--border-bright);
  transform: translateY(-3px);
}
.email-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.email-address {
  font-size: 1.05rem;
  font-weight: 800;
  color: #ffffff;
  font-family: var(--font-mono);
}

.copy-pill-btn,
.tool-copy {
  margin-top: 4px;
  background: var(--bg-pill);
  border: 1px solid var(--border-subtle);
  color: var(--text-gray);
  padding: 6px 16px;
  border-radius: var(--radius-full);
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
  flex-shrink: 0;
}
.copy-pill-btn:hover,
.tool-copy:hover {
  background: #ffffff;
  color: #000000;
  border-color: #ffffff;
}

.contact-meta-row {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  justify-content: center;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-dim);
}

/* ==========================================================================
   STATS
   ========================================================================== */
.stats-row {
  position: relative;
  z-index: 10;
  max-width: 1100px;
  margin: -40px auto 0;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.stat-glow {
  position: absolute;
  width: min(480px, 75vw);
  height: 140px;
  background: radial-gradient(ellipse, rgba(255, 255, 255, 0.05) 0%, transparent 65%);
  filter: blur(30px);
  pointer-events: none;
}
.stat-sentence {
  position: relative;
  display: flex;
  align-items: baseline;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.22em;
  text-align: center;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: -0.04em;
  line-height: 1;
  font-size: clamp(1.8rem, 4.2vw, 3rem);
  color: #ffffff;
}
.stat-over {
  font-weight: 800;
  color: var(--text-muted);
}
.stat-big {
  background: linear-gradient(180deg, #ffffff 30%, #a1a1aa 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-variant-numeric: tabular-nums;
}
.stat-rest { color: var(--text-muted); }

/* ==========================================================================
   SPOTLIGHT — poświata podążająca za myszką na kartach
   ========================================================================== */
.focus-card::after,
.project-strip::after,
.contact-box::after,
.tool-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  opacity: 0;
  transition: opacity 0.35s ease;
  pointer-events: none;
  background: radial-gradient(340px circle at var(--mx, 50%) var(--my, 50%), rgba(255, 255, 255, 0.09), transparent 65%);
}
.focus-card:hover::after,
.project-strip:hover::after,
.contact-box:hover::after,
.tool-card:hover::after { opacity: 1; }
.project-strip { position: relative; overflow: hidden; }

/* ==========================================================================
   ACTIVE NAV LINK
   ========================================================================== */
.nav-link.is-active {
  color: var(--text-white);
  background: var(--bg-pill);
}

/* ==========================================================================
   TOOLBOX
   ========================================================================== */
.tools-hero { padding-top: 170px; }
.tools-header { text-align: center; display: flex; flex-direction: column; align-items: center; }
.tools-wrap {
  max-width: 760px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.tabs {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: center;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 6px;
  backdrop-filter: blur(20px);
}
.tab {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--text-dim);
  background: transparent;
  border: none;
  border-radius: var(--radius-full);
  padding: 9px 18px;
  transition: all var(--transition-fast);
}
.tab:hover { color: var(--text-white); }
.tab.active {
  background: #ffffff;
  color: #000000;
}
.tool-card.tool-panel { display: none; }
.tool-card.tool-panel.active { display: flex; }
.color-top {
  display: flex;
  gap: 12px;
  align-items: stretch;
}
.sv-box {
  position: relative;
  flex: 1;
  min-height: 190px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: hsl(160, 100%, 50%);
  touch-action: none;
  overflow: hidden;
}
.sv-white, .sv-black {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
}
.sv-white { background: linear-gradient(90deg, #ffffff, transparent); }
.sv-black { background: linear-gradient(0deg, #000000, transparent); }
.sv-dot {
  position: absolute;
  width: 16px;
  height: 16px;
  border: 2px solid #ffffff;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.45), 0 2px 8px rgba(0, 0, 0, 0.5);
  pointer-events: none;
}
.color-side {
  width: 148px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.color-side .tool-area { text-align: center; text-transform: uppercase; }
.color-preview {
  flex: 1;
  min-height: 64px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: #10b981;
  transition: background-color 0.15s ease;
}
.hue-swatches {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 8px;
}
.swatch {
  aspect-ratio: 1;
  border-radius: 10px;
  border: 1px solid var(--border-subtle);
  transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}
.swatch:hover { transform: translateY(-2px) scale(1.06); border-color: #ffffff; }
.swatch.active {
  border-color: #ffffff;
  box-shadow: 0 0 0 2px #000000, 0 0 0 3px #ffffff;
}
/* Custom kalendarz */
.cal-wrap { position: relative; }
.tool-date-btn { text-align: left; width: 100%; font-family: var(--font-mono); }
.cal-popup {
  position: fixed;
  width: min(300px, calc(100vw - 32px));
  z-index: 9000;
  background: #0c0c0e;
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-md);
  padding: 14px;
  display: none;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.8);
}
.cal-popup.open { display: block; }
.cal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  font-weight: 800;
  font-size: 0.9rem;
  text-transform: capitalize;
}
.cal-nav {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--bg-pill);
  border: 1px solid var(--border-subtle);
  color: #ffffff;
  font-size: 1rem;
  line-height: 1;
  transition: all var(--transition-fast);
}
.cal-nav:hover { background: #ffffff; color: #000000; }
.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
}
.cal-dow {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  font-weight: 700;
  color: var(--text-muted);
  text-align: center;
  padding: 4px 0;
  text-transform: uppercase;
}
.cal-day {
  aspect-ratio: 1;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 10px;
  color: var(--text-gray);
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 700;
  transition: all 0.12s ease;
}
.cal-day:hover:not(.blank) { border-color: var(--border-medium); color: #ffffff; }
.cal-day.today { border-color: var(--border-medium); }
.cal-day.sel { background: #ffffff; color: #000000; }
.cal-day.blank { visibility: hidden; }
.cal-time {
  display: flex;
  gap: 8px;
  margin-top: 12px;
  align-items: center;
  justify-content: center;
}
.cal-time input {
  width: 64px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  color: #ffffff;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  padding: 8px 10px;
  text-align: center;
}
.cal-time input:focus { outline: none; border-color: var(--border-bright); }
.cal-time span { color: var(--text-dim); font-weight: 800; }
.tool-card {
  background: var(--bg-card);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 32px 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  position: relative;
  transition: border-color var(--transition-normal);
}
.tool-card:hover { border-color: var(--border-medium); }
.tool-head {
  display: flex;
  align-items: center;
  gap: 14px;
}
.tool-head h3 {
  font-size: 1.2rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}
.tool-num {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 800;
  color: var(--text-muted);
}
.tool-hint {
  font-size: 0.9rem;
  color: var(--text-gray);
}
.tool-row-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-gray);
}
.tool-len-val {
  font-family: var(--font-mono);
  color: #ffffff;
  background: var(--bg-pill);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 2px 14px;
  font-size: 0.85rem;
}
.tool-range {
  width: 100%;
  accent-color: #ffffff;
  height: 28px;
}
.tool-checks {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.tool-check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-gray);
  background: var(--bg-pill);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 6px 14px;
  transition: all var(--transition-fast);
  user-select: none;
}
.tool-check:has(input:checked) {
  color: #ffffff;
  border-color: var(--border-medium);
}
.tool-check input { accent-color: var(--accent-emerald); }
.tool-out {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px 16px;
}
.tool-out code {
  flex: 1;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: #ffffff;
  word-break: break-all;
  min-width: 0;
}
.tool-out-col { flex-direction: column; align-items: stretch; }
.tool-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.btn-tool {
  padding: 10px 22px;
  font-size: 0.85rem;
}
.strength { display: flex; align-items: center; gap: 12px; }
.strength-bar {
  flex: 1;
  height: 6px;
  border-radius: var(--radius-full);
  background: var(--bg-pill);
  overflow: hidden;
}
.strength-bar span {
  display: block;
  height: 100%;
  width: 0;
  border-radius: var(--radius-full);
  background: var(--accent-emerald);
  transition: width 0.3s ease, background-color 0.3s ease;
}
.strength-label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-dim);
  min-width: 70px;
  text-align: right;
}
.tool-area {
  width: 100%;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  color: #ffffff;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  padding: 12px 16px;
  resize: vertical;
  transition: border-color var(--transition-fast);
}
.tool-area:focus { outline: none; border-color: var(--border-bright); }
.tool-area-code { font-family: var(--font-mono); font-size: 0.82rem; }
.tool-area::placeholder { color: var(--text-muted); }
.tool-msg {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 700;
  min-height: 1.2em;
}
.tool-msg.ok { color: var(--accent-emerald); }
.tool-msg.err { color: #f87171; }
.tiny-label {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  min-width: 96px;
  flex-shrink: 0;
}
.mini-stats {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.mini-stat {
  flex: 1;
  min-width: 100px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 12px 10px;
  text-align: center;
}
.mini-stat b {
  display: block;
  font-size: 1.5rem;
  font-weight: 800;
  color: #ffffff;
  font-variant-numeric: tabular-nums;
}
.mini-stat span {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-dim);
}
.unit-cat.active {
  background: #ffffff;
  color: #000000;
  border-color: #ffffff;
}
.unit-grid {
  display: grid;
  grid-template-columns: 1fr 1fr auto 1fr;
  gap: 10px;
  align-items: center;
}
.unit-grid input,
.unit-grid select,
.tool-date {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  color: #ffffff;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  padding: 10px 12px;
  min-width: 0;
}
.unit-grid input:focus,
.unit-grid select:focus,
.tool-date:focus { outline: none; border-color: var(--border-bright); }
.unit-arrow { color: var(--text-dim); font-weight: 800; text-align: center; }
.unit-result {
  font-family: var(--font-mono);
  font-size: 1.1rem;
  font-weight: 700;
  color: #ffffff;
  background: var(--bg-pill);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  text-align: center;
  word-break: break-all;
}
.tool-field-label {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-gray);
}
.tool-date { width: 100%; color-scheme: dark; }
.cd-display {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}
.cd-cell {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px 8px;
  text-align: center;
}
.cd-cell b {
  display: block;
  font-size: clamp(1.6rem, 5vw, 2.4rem);
  font-weight: 900;
  color: #ffffff;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.cd-cell span {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-dim);
}
.embed-box {
  display: flex;
  flex-direction: column;
  gap: 12px;
  border-top: 1px solid var(--border-subtle);
  padding-top: 16px;
}
.embed-box[hidden] { display: none; }
.embed-prev {
  width: 100%;
  height: 168px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  background: transparent;
}
@media (max-width: 560px) {
  .unit-grid { grid-template-columns: 1fr 1fr; }
  .unit-arrow { display: none; }
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.footer {
  position: relative;
  z-index: 10;
  border-top: 1px solid var(--border-subtle);
  padding: 40px 24px;
}
.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  font-size: 0.88rem;
}
.footer-left {
  color: var(--text-dim);
}
.footer-left strong {
  color: #ffffff;
}
.footer-right {
  display: flex;
  align-items: center;
  gap: 18px;
}
.footer-clock {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.footer-clock b { color: var(--accent-emerald); font-weight: 700; }
.footer-anchor {
  color: var(--text-gray);
  text-decoration: none;
  font-weight: 600;
  transition: color var(--transition-fast);
}
.footer-anchor:hover {
  color: #ffffff;
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 900px) {
  .focus-grid {
    grid-template-columns: 1fr;
  }
  .tools-wrap { max-width: 100%; }
  .tabs { border-radius: var(--radius-lg); }
  .project-strip {
    flex-direction: column;
    align-items: flex-start;
  }
  .orbit-system {
    width: 600px;
    height: 600px;
  }
  .orbit-track-2 { display: none; }
}

@media (max-width: 680px) {
  .nav-links { display: none; }
  .nav-bar { gap: 12px; padding: 8px 10px 8px 14px; }
  .nav-cta { min-width: 0; padding: 8px 14px; }
  .section { padding: 70px 20px; }
  .contact-box { padding: 40px 24px; }
}
