/* ==========================================================================
   ANTONIJO KRSTIC — GRAINY PORTFOLIO (#6900FF / #F86C00)
   2 Schriften: Arial Black + Arial | 0px Radius | 1px Hairlines
   ========================================================================== */

:root {
  --font-display: "Arial Black", "Arial-BoldMT", "Helvetica Neue", Impact, sans-serif;
  --font-mono: Arial, "Helvetica Neue", Helvetica, sans-serif;
  --arial-size: clamp(13px, 0.95vw, 15px);

  --accent: #6900FF;
  --accent-ink: #F4F4F0;
  --client-accent: #F86C00;
  --border-w: 1px;

  --bg: #080808;
  --surface: #111111;
  --surface-alt: #171717;
  --ink: #F2F2EE;
  --ink-muted: #A3A39E;
  --line: rgba(242, 242, 238, 0.2);
  --line-strong: rgba(242, 242, 238, 0.45);
  --scrim: linear-gradient(180deg, rgba(8, 8, 8, 0.48) 0%, rgba(8, 8, 8, 0.88) 100%);
  --grain-opacity: 0.12;
  --grain-blend: screen;

  --archive-bar-bg: #080808;
  --archive-bar-ink: #F2F2EE;
  --archive-bar-line: rgba(242, 242, 238, 0.22);
}

*,
*::before,
*::after {
  box-sizing: border-box;
  border-radius: 0 !important;
}

html {
  scroll-behavior: smooth;
  background-color: var(--bg);
  color: var(--ink);
}

body {
  margin: 0;
  font-family: var(--font-mono);
  font-size: var(--arial-size);
  line-height: 1.55;
  background-color: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  background-image: radial-gradient(rgba(128, 128, 128, 0.08) 1px, transparent 0);
  background-size: 4px 4px;
}

.grain-layer {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 900;
  opacity: var(--grain-opacity);
  mix-blend-mode: var(--grain-blend);
  background-repeat: repeat;
  background-size: 220px 220px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220' viewBox='0 0 220 220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.88' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='220' height='220' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
}

img {
  display: block;
  max-width: 100%;
}

[hidden] {
  display: none !important;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea {
  font-family: var(--font-mono);
  font-size: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  background: transparent;
  border: none;
  padding: 0;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

h1,
h2,
h3,
.card-title,
.list-title {
  font-family: var(--font-display);
  font-weight: 900;
  letter-spacing: -0.05em;
  line-height: 0.96;
  margin: 0;
  text-transform: uppercase;
}

.brand {
  font-family: var(--font-display);
  font-weight: 900;
  letter-spacing: -0.04em;
  line-height: 1;
  margin: 0;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 500;
  display: flex;
  justify-content: space-between;
  align-items: stretch;
  background: var(--bg);
  border-bottom: var(--border-w) solid var(--line-strong);
  min-height: 52px;
}

.brand {
  display: flex;
  align-items: center;
  padding: 14px 24px;
  font-size: 16px;
  border-right: var(--border-w) solid var(--line);
  white-space: nowrap;
  flex-shrink: 0;
}

.site-nav {
  display: flex;
  align-items: stretch;
  flex-wrap: nowrap;
}

.site-nav a {
  display: flex;
  align-items: center;
  padding: 14px 22px;
  font-size: 12px;
  letter-spacing: 0.05em;
  white-space: nowrap;
  flex-shrink: 0;
  border-left: var(--border-w) solid var(--line);
  transition: background-color 0.15s ease, color 0.15s ease;
}

.site-nav a:hover {
  background: var(--accent);
  color: var(--accent-ink);
}

.nav-burger {
  display: none;
  align-items: center;
  gap: 10px;
  padding: 0 20px;
  font-size: 12px;
  letter-spacing: 0.06em;
  white-space: nowrap;
  flex-shrink: 0;
  border-left: var(--border-w) solid var(--line);
  transition: background-color 0.15s ease, color 0.15s ease;
}

.nav-burger:hover,
.nav-burger.is-open {
  background: var(--accent);
  color: var(--accent-ink);
}

.burger-lines {
  display: inline-flex;
  flex-direction: column;
  justify-content: space-between;
  width: 15px;
  height: 11px;
}

.burger-lines span {
  display: block;
  width: 100%;
  height: 1.5px;
  background: currentColor;
}

.mobile-nav-drawer {
  position: sticky;
  top: 52px;
  z-index: 490;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  border-bottom: var(--border-w) solid var(--line-strong);
}

.mobile-nav-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  font-size: 13px;
  letter-spacing: 0.06em;
  border-bottom: var(--border-w) solid var(--line);
  transition: background-color 0.15s ease, color 0.15s ease;
}

.mobile-nav-link:last-child {
  border-bottom: none;
}

.mobile-nav-link:hover {
  background: var(--accent);
  color: var(--accent-ink);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 22px;
  font-size: 12px;
  letter-spacing: 0.05em;
  border: var(--border-w) solid var(--line-strong);
  background: var(--bg);
  color: var(--ink);
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.btn:hover {
  background: var(--ink);
  color: var(--bg);
}

.btn-accent {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}

.btn-accent:hover {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--bg);
}

.hero {
  position: relative;
  min-height: 76vh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-bottom: var(--border-w) solid var(--line-strong);
  overflow: hidden;
}

.hero-bg-wrap {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-bg-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 42%;
  filter: grayscale(100%) contrast(1.14);
}

.hero-scrim {
  position: absolute;
  inset: 0;
  background: var(--scrim);
}

.hero-stage {
  position: relative;
  z-index: 2;
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: clamp(22px, 3vw, 36px) clamp(20px, 4vw, 48px) clamp(32px, 5vw, 56px);
  gap: 36px;
}

.hero-topline {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  font-size: 11px;
  letter-spacing: 0.07em;
  color: var(--ink-muted);
}

.hero-status {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--ink);
}

.hero-status-dot {
  width: 8px;
  height: 8px;
  background: var(--accent);
  flex-shrink: 0;
}

.hero-headline-block {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.hero-title {
  font-size: clamp(2.8rem, 7.6vw, 7.2rem);
  letter-spacing: -0.055em;
  line-height: 0.92;
  max-width: 15ch;
}

.hero-bottom-split {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  padding-top: 8px;
}

.hero-lead {
  max-width: 54ch;
  margin: 0;
  color: var(--ink);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero-strip {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-top: var(--border-w) solid var(--line-strong);
  background: rgba(8, 8, 8, 0.72);
}

.strip-cell {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 18px 24px;
  border-right: var(--border-w) solid var(--line);
  text-align: left;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.strip-cell:last-child {
  border-right: none;
}

.strip-cell:hover {
  background: var(--accent);
  color: var(--accent-ink);
}

.strip-cell:hover .strip-arrow {
  transform: translate(2px, -2px);
}

.strip-name {
  font-family: var(--font-display);
  font-size: clamp(0.9rem, 1.25vw, 1.15rem);
  letter-spacing: -0.04em;
}

.strip-meta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  flex-shrink: 0;
}

.strip-arrow {
  opacity: 0.75;
  transition: transform 0.15s ease;
}

.section {
  border-bottom: var(--border-w) solid var(--line-strong);
}

.section-bar {
  display: flex;
  justify-content: space-between;
  align-items: stretch;
  border-bottom: var(--border-w) solid var(--line);
}

.archive-bar-grain {
  background-color: var(--archive-bar-bg);
  color: var(--archive-bar-ink);
  border-bottom-color: var(--archive-bar-line);
  background-image:
    radial-gradient(rgba(242, 242, 238, 0.11) 1px, transparent 0),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180' viewBox='0 0 180 180'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23g)' opacity='0.16'/%3E%3C/svg%3E");
  background-size: 4px 4px, 180px 180px;
}

.archive-bar-grain .section-title {
  color: var(--archive-bar-ink);
}

.archive-bar-grain .filter-toggle {
  color: var(--archive-bar-ink);
  border-left-color: var(--archive-bar-line);
}

.archive-bar-grain .filter-toggle:hover {
  background: var(--archive-bar-ink);
  color: var(--archive-bar-bg);
}

.section-title {
  padding: 20px 24px;
  font-size: clamp(1.4rem, 2.6vw, 2.2rem);
}

.archive-title-group {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-right: 16px;
  min-width: 0;
}

.archive-client-hint {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--client-accent);
  background: rgba(8, 8, 8, 0.85);
  opacity: 0.85;
  padding: 4px 8px;
  border: 1px solid var(--client-accent);
  white-space: nowrap;
  transition: opacity 0.15s ease, background-color 0.15s ease, color 0.15s ease;
}

.archive-client-hint:hover,
.archive-client-hint:focus-visible {
  opacity: 1;
  background: var(--client-accent);
  color: #080808;
}

.control-cell {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 16px;
  font-size: 12px;
  letter-spacing: 0.03em;
  color: var(--ink);
  transition: background-color 0.15s ease, color 0.15s ease;
}

.control-cell:hover {
  background: var(--surface-alt);
}

.control-cell.is-active {
  background: var(--accent);
  color: var(--accent-ink);
}

.filter-toggle {
  gap: 8px;
  padding: 12px 20px;
  border-left: var(--border-w) solid var(--line-strong);
}

.filter-icon {
  display: block;
  flex-shrink: 0;
}

.filter-panel {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  width: 100%;
  border-bottom: var(--border-w) solid var(--line-strong);
  background: var(--surface);
  overflow: hidden;
}

.fp-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 14px 18px;
  border-right: var(--border-w) solid var(--line);
  border-bottom: var(--border-w) solid var(--line);
  margin-bottom: -1px;
}

.fp-section-cat {
  flex: 1 1 auto;
}

.fp-section:last-child {
  border-right: none;
}

.fp-label {
  font-size: 10px;
  letter-spacing: 0.1em;
  opacity: 0.55;
  user-select: none;
  pointer-events: none;
}

.fp-group {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  border: var(--border-w) solid var(--line);
  width: fit-content;
  max-width: 100%;
  background: var(--bg);
}

.fp-group .control-cell {
  border-right: var(--border-w) solid var(--line);
  padding: 7px 12px;
  font-size: 11px;
}

.fp-group .control-cell:last-child {
  border-right: none;
}

.fp-group .control-cell.filter-cell-client {
  color: var(--client-accent);
}

.fp-group .control-cell.filter-cell-client.is-active,
.fp-group .control-cell.filter-cell-client:hover {
  background: var(--client-accent);
  color: #080808;
}

.search-box {
  display: inline-flex;
  align-items: center;
  border: var(--border-w) solid var(--line);
  background: var(--bg);
  min-width: 210px;
  max-width: 100%;
}

.search-box input {
  flex: 1 1 auto;
  min-width: 0;
  border: none;
  background: transparent;
  padding: 7px 10px;
  font-size: 11px;
  color: var(--ink);
}

.search-box input::placeholder {
  color: var(--ink-muted);
  opacity: 0.7;
}

.search-box input:focus {
  outline: none;
}

.search-box:focus-within {
  border-color: var(--accent);
}

.search-clear {
  padding: 0 9px;
  font-size: 11px;
  color: var(--ink-muted);
  align-self: stretch;
  border-left: var(--border-w) solid var(--line);
}

.search-clear:hover {
  background: var(--accent);
  color: var(--accent-ink);
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: stretch;
}

.portfolio-grid.is-masonry .masonry-col {
  display: flex;
  flex-direction: column;
  border-right: var(--border-w) solid var(--line);
  min-width: 0;
}

.portfolio-grid.is-masonry .masonry-col:last-child {
  border-right: none;
}

.project-card {
  display: flex;
  flex-direction: column;
  border-right: var(--border-w) solid var(--line);
  border-bottom: var(--border-w) solid var(--line);
  background: var(--bg);
  cursor: pointer;
  transition: background-color 0.15s ease;
}

.portfolio-grid.is-masonry .project-card,
.portfolio-grid.is-masonry .project-stack-slot {
  border-right: none;
  border-bottom: var(--border-w) solid var(--line);
}

.portfolio-grid.is-digicam-grid .project-card:nth-child(3n) {
  border-right: none;
}

.project-card:hover {
  background: var(--surface);
}

.card-media {
  position: relative;
  width: 100%;
  overflow: hidden;
  background: var(--surface-alt);
  border-bottom: var(--border-w) solid var(--line);
}

.card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.project-card:hover .card-media img {
  transform: scale(1.03);
}

.card-pin {
  position: absolute;
  top: 0;
  left: 0;
  padding: 6px 10px;
  font-size: 11px;
  background: var(--accent);
  color: var(--accent-ink);
  border-right: var(--border-w) solid var(--line-strong);
  border-bottom: var(--border-w) solid var(--line-strong);
}

.card-slides-count {
  position: absolute;
  bottom: 0;
  right: 0;
  padding: 5px 9px;
  font-size: 11px;
  background: var(--bg);
  color: var(--ink);
  border-top: var(--border-w) solid var(--line-strong);
  border-left: var(--border-w) solid var(--line-strong);
}

.card-body {
  padding: 16px 18px 18px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.card-title {
  font-size: 1.15rem;
}

.project-client-tag {
  color: var(--client-accent);
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.72em;
  letter-spacing: 0.04em;
  vertical-align: middle;
}

.card-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 12px;
  color: var(--ink-muted);
  margin-top: auto;
  padding-top: 8px;
  border-top: var(--border-w) solid var(--line);
}

.project-stack-slot {
  display: flex;
  flex-direction: column;
  background: var(--bg);
}

.project-stack-slot .project-card.is-stacked-item {
  border-right: none;
  flex: 1 1 0;
}

.project-stack-slot .project-card.is-stacked-item:last-child {
  border-bottom: none;
}

.portfolio-list {
  display: flex;
  flex-direction: column;
}

.list-row {
  display: grid;
  grid-template-columns: 84px 1.6fr 1fr 90px 100px;
  align-items: center;
  border-bottom: var(--border-w) solid var(--line);
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.list-row:hover {
  background: var(--accent);
  color: var(--accent-ink);
}

.list-thumb {
  width: 84px;
  height: 64px;
  object-fit: cover;
  border-right: var(--border-w) solid var(--line);
}

.list-title {
  padding: 16px 20px;
  font-size: 1.05rem;
}

.list-cat,
.list-year,
.list-slides {
  padding: 16px;
  font-size: 12px;
  border-left: var(--border-w) solid var(--line);
}

.empty-state {
  padding: 48px 24px;
  font-size: 13px;
  color: var(--ink-muted);
}

.about-section {
  --bg: #ECEAE3;
  --surface: #E3E0D7;
  --surface-alt: #D8D4C9;
  --ink: #0A0A0A;
  --ink-muted: #464642;
  --line: rgba(10, 10, 10, 0.22);
  --line-strong: rgba(10, 10, 10, 0.55);
  background-color: var(--bg);
  color: var(--ink);
  background-image: radial-gradient(rgba(10, 10, 10, 0.08) 1px, transparent 0);
  background-size: 4px 4px;
}

.about-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
}

.about-copy {
  padding: clamp(24px, 4vw, 48px);
  border-right: var(--border-w) solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.about-statement {
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 2.2vw, 1.85rem);
  letter-spacing: -0.04em;
  line-height: 1.1;
  margin: 0;
  text-transform: uppercase;
}

.about-copy p {
  margin: 0;
  max-width: 64ch;
}

.about-specs {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  height: 100%;
}

.about-specs .spec-row {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
  padding: 20px 22px;
  border-bottom: var(--border-w) solid var(--line);
  border-right: var(--border-w) solid var(--line);
  background-color: var(--box-bg, transparent);
  transition: background-color 0.18s ease, color 0.18s ease;
}

.about-specs .spec-row:nth-child(2n) {
  border-right: none;
}

.about-specs .spec-row:nth-last-child(-n + 2) {
  border-bottom: none;
}

.about-specs .spec-row.has-bg-image::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--box-img);
  background-size: cover;
  background-position: center;
  opacity: 0.32;
  z-index: 0;
  transition: transform 0.35s ease, opacity 0.2s ease;
  pointer-events: none;
}

.about-specs .spec-row:hover.has-bg-image::before {
  transform: scale(1.04);
  opacity: 0.44;
}

.about-specs .spec-row > * {
  position: relative;
  z-index: 1;
}

.about-specs .spec-row:hover {
  background-color: var(--box-bg, var(--surface));
}

.about-specs .spec-row-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.spec-key {
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--ink-muted);
  opacity: 0.75;
  transition: color 0.15s ease, opacity 0.15s ease;
}

.spec-val {
  font-size: 13px;
  line-height: 1.45;
}

.about-specs .spec-row:hover .spec-key {
  color: var(--accent);
  opacity: 1;
}

.about-specs .spec-arrow {
  font-size: 11px;
  opacity: 0.5;
  transition: transform 0.15s ease, opacity 0.15s ease, color 0.15s ease;
}

.about-specs .spec-row:hover .spec-arrow {
  opacity: 1;
  color: var(--accent);
  transform: translate(2px, -2px);
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.35fr;
}

.contact-direct {
  padding: clamp(24px, 4vw, 48px);
  border-right: var(--border-w) solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.contact-intro {
  margin: 0;
  max-width: 46ch;
}

.direct-box {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
  padding: 20px;
  border: var(--border-w) solid var(--line-strong);
  background: var(--surface);
}

.direct-email {
  font-family: var(--font-display);
  font-size: clamp(1rem, 1.8vw, 1.4rem);
  letter-spacing: -0.04em;
  word-break: break-all;
}

.direct-email:hover {
  color: var(--accent);
}

.social-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-top: var(--border-w) solid var(--line);
  border-left: var(--border-w) solid var(--line);
}

.social-link {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 16px;
  font-size: 12px;
  border-right: var(--border-w) solid var(--line);
  border-bottom: var(--border-w) solid var(--line);
  transition: background-color 0.15s ease, color 0.15s ease;
}

.social-link:hover {
  background: var(--accent);
  color: var(--accent-ink);
}

.contact-form {
  padding: clamp(24px, 4vw, 48px);
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-label {
  font-size: 12px;
  color: var(--ink-muted);
}

.form-row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.scope-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-top: var(--border-w) solid var(--line-strong);
  border-left: var(--border-w) solid var(--line-strong);
}

.scope-cell {
  padding: 13px 14px;
  font-size: 12px;
  text-align: left;
  border-right: var(--border-w) solid var(--line-strong);
  border-bottom: var(--border-w) solid var(--line-strong);
  background: var(--bg);
  transition: background-color 0.15s ease, color 0.15s ease;
}

.scope-cell:hover {
  background: var(--surface);
}

.scope-cell.is-selected {
  background: var(--accent);
  color: var(--accent-ink);
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form textarea {
  width: 100%;
  padding: 13px 14px;
  background: var(--surface);
  border: var(--border-w) solid var(--line-strong);
  color: var(--ink);
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--accent);
}

.form-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
}

.form-status {
  margin: 0;
  font-size: 12px;
  color: var(--ink-muted);
}

.form-status.is-ok {
  color: var(--ink);
  border-left: 3px solid var(--accent);
  padding-left: 10px;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  align-items: stretch;
  font-size: 12px;
  background: var(--surface);
}

.footer-left {
  padding: 18px 24px;
  color: var(--ink-muted);
}

.footer-right {
  display: flex;
}

.footer-link {
  display: flex;
  align-items: center;
  padding: 18px 20px;
  font-size: 12px;
  border-left: var(--border-w) solid var(--line);
  transition: background-color 0.15s ease, color 0.15s ease;
}

.footer-link:hover {
  background: var(--accent);
  color: var(--accent-ink);
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal[hidden] {
  display: none;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.84);
}

.modal-panel {
  position: relative;
  z-index: 2;
  width: min(1240px, 100%);
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  border: var(--border-w) solid var(--line-strong);
  overflow: hidden;
}

.modal-topbar {
  display: flex;
  justify-content: space-between;
  align-items: stretch;
  flex-shrink: 0;
  border-bottom: var(--border-w) solid var(--line-strong);
  background: var(--surface);
}

.lb-meta-bar {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 18px;
  font-size: 12px;
  min-width: 0;
}

.lb-meta-bar span,
.modal-actions .control-cell {
  white-space: nowrap;
}

#lb-slide-counter {
  margin-left: auto;
}

.modal-actions {
  display: flex;
  flex-shrink: 0;
}

.modal-actions .control-cell {
  border-left: var(--border-w) solid var(--line);
}

.lb-body {
  display: grid;
  grid-template-columns: 1.65fr 1fr;
  min-height: 0;
  flex: 1;
  overflow: auto;
}

.lb-stage {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  background: var(--surface-alt);
  border-right: var(--border-w) solid var(--line);
  padding: 28px 60px;
  min-height: 420px;
}

.lb-figure {
  margin: auto 0;
  width: 100%;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.lb-figure > img {
  max-height: 68vh;
  max-width: 100%;
  width: auto;
  object-fit: contain;
  border: var(--border-w) solid var(--line);
}

.lb-figure figcaption {
  width: 100%;
  font-size: 12px;
  color: var(--ink-muted);
  text-align: left;
}

.lb-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 42px;
  height: 54px;
  border: var(--border-w) solid var(--line-strong);
  background: var(--bg);
  color: var(--ink);
  font-size: 16px;
}

.lb-nav:hover {
  background: var(--accent);
  color: var(--accent-ink);
  border-color: var(--accent);
}

.lb-prev {
  left: 10px;
}

.lb-next {
  right: 10px;
}

.lb-info {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.lb-title {
  font-size: 1.5rem;
}

.lb-desc {
  margin: 0;
  font-size: 13px;
}

.lb-specs {
  border-top: var(--border-w) solid var(--line);
  border-bottom: var(--border-w) solid var(--line);
}

.lb-specs .spec-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 14px 0;
  border-bottom: var(--border-w) solid var(--line);
}

.lb-specs .spec-row:last-child {
  border-bottom: none;
}

.lb-thumbs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: auto;
}

.lb-thumb {
  aspect-ratio: 1 / 1;
  border: var(--border-w) solid var(--line);
  overflow: hidden;
}

.lb-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.lb-thumb.is-active {
  border: 2px solid var(--accent);
}

.legal-panel {
  width: min(760px, 100%);
}

.legal-heading {
  padding: 14px 20px;
  font-size: 1.1rem;
}

.legal-body {
  padding: 24px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
  font-size: 13px;
}

.legal-body h4 {
  font-family: var(--font-display);
  letter-spacing: -0.04em;
  margin: 8px 0 0;
  font-size: 1rem;
  text-transform: uppercase;
}

.legal-body p {
  margin: 0;
}

.lb-compare {
  display: flex;
  justify-content: center;
  width: 100%;
  --pos: 50%;
}

.lb-compare-stage {
  position: relative;
  width: min(100%, 640px);
  aspect-ratio: 4 / 5;
  max-height: 66vh;
  overflow: hidden;
  user-select: none;
  border: var(--border-w) solid var(--line-strong);
  background: #000;
}

.lb-compare-after {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
  pointer-events: none;
}

.lb-compare-before-wrap {
  position: absolute;
  inset: 0;
  clip-path: inset(0 calc(100% - var(--pos, 50%)) 0 0);
  pointer-events: none;
}

.lb-compare.is-slide-anim:not(.is-settled) .lb-compare-before-wrap {
  animation: compare-clip-from-right 1.15s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.lb-compare-before {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
}

.lb-compare-tag {
  position: absolute;
  top: 12px;
  z-index: 2;
  padding: 4px 8px;
  font-size: 10px;
  letter-spacing: 0.08em;
  background: rgba(0, 0, 0, 0.78);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.25);
  pointer-events: none;
}

.lb-compare-tag-before {
  left: 12px;
}

.lb-compare-tag-after {
  right: 12px;
}

.lb-compare-handle {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--pos, 50%);
  width: 2px;
  background: var(--accent);
  transform: translateX(-50%);
  z-index: 3;
  pointer-events: none;
}

.lb-compare.is-slide-anim:not(.is-settled) .lb-compare-handle {
  animation: compare-slide-from-right 1.15s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.lb-compare-handle span {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  background: var(--accent);
  color: #fff;
  font-size: 14px;
  border: 1px solid #fff;
}

@keyframes compare-slide-from-right {
  from {
    left: 100%;
  }
  to {
    left: var(--pos, 50%);
  }
}

@keyframes compare-clip-from-right {
  from {
    clip-path: inset(0 0% 0 0);
  }
  to {
    clip-path: inset(0 calc(100% - var(--pos, 50%)) 0 0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .lb-compare-handle,
  .lb-compare-before-wrap {
    animation: none !important;
  }
}

.lb-compare-range {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: ew-resize;
  z-index: 4;
}

.lb-transfer {
  margin: 14px auto 0;
  border: var(--border-w) solid var(--line-strong);
  background: var(--bg);
  text-align: left;
  width: 100%;
  max-width: 640px;
}

.lb-transfer-head {
  padding: 8px 14px;
  font-size: 11px;
  letter-spacing: 0.08em;
  border-bottom: var(--border-w) solid var(--line);
  color: var(--accent);
}

.lb-transfer-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.lb-transfer-list li {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  gap: 10px;
  padding: 10px 14px;
  font-size: 12px;
  line-height: 1.5;
  border-bottom: var(--border-w) solid var(--line);
  overflow-wrap: anywhere;
}

.lb-transfer-list li:last-child {
  border-bottom: none;
}

.lb-transfer-num {
  color: var(--accent);
  font-size: 11px;
  opacity: 0.9;
}

@media (max-width: 1024px) {
  .hero-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .strip-cell:nth-child(2n) {
    border-right: none;
  }

  .strip-cell:nth-child(-n + 2) {
    border-bottom: var(--border-w) solid var(--line);
  }

  .about-grid,
  .contact-grid,
  .lb-body {
    grid-template-columns: 1fr;
  }

  .about-copy,
  .contact-direct,
  .lb-stage {
    border-right: none;
    border-bottom: var(--border-w) solid var(--line);
  }

  .portfolio-grid,
  .portfolio-grid.is-digicam-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .portfolio-grid.is-digicam-grid .project-card:nth-child(3n) {
    border-right: var(--border-w) solid var(--line);
  }

  .portfolio-grid.is-digicam-grid .project-card:nth-child(2n) {
    border-right: none;
  }
}

@media (max-width: 900px) {
  .site-nav {
    display: none;
  }

  .nav-burger {
    display: inline-flex;
  }

  .fp-section {
    flex: 1 1 100%;
    border-right: none;
    border-bottom: var(--border-w) solid var(--line);
    padding: 12px 14px;
  }

  .fp-section:last-child {
    border-bottom: none;
  }
}

@media (max-width: 768px) {
  .brand {
    padding: 14px 18px;
    font-size: 14px;
  }

  .hero {
    min-height: auto;
  }

  .hero-strip,
  .portfolio-grid,
  .portfolio-grid.is-digicam-grid,
  .about-specs,
  .form-row-2,
  .scope-grid,
  .social-links {
    grid-template-columns: 1fr;
  }

  .strip-cell {
    border-right: none;
    border-bottom: var(--border-w) solid var(--line);
  }

  .strip-cell:last-child {
    border-bottom: none;
  }

  .portfolio-grid.is-masonry .masonry-col,
  .portfolio-grid.is-digicam-grid .project-card {
    border-right: none;
  }

  .about-specs .spec-row {
    border-right: none;
    border-bottom: var(--border-w) solid var(--line);
  }

  .about-specs .spec-row:last-child {
    border-bottom: none;
  }

  .list-row {
    grid-template-columns: 64px 1fr 70px;
  }

  .list-cat,
  .list-slides {
    display: none;
  }

  .site-footer {
    flex-direction: column;
  }

  .footer-right {
    border-top: var(--border-w) solid var(--line);
  }

  .footer-link {
    flex: 1;
    justify-content: center;
    border-left: none;
    border-right: var(--border-w) solid var(--line);
  }

  .footer-link:last-child {
    border-right: none;
  }

  .modal {
    padding: 0;
  }

  .modal-panel {
    width: 100%;
    height: 100dvh;
    max-height: 100dvh;
    border: none;
  }

  .modal-topbar {
    flex-direction: column;
    align-items: stretch;
  }

  .lb-meta-bar {
    padding: 10px 14px;
    border-bottom: var(--border-w) solid var(--line);
    justify-content: space-between;
    font-size: 11px;
  }

  .modal-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: 100%;
  }

  .modal-actions .control-cell {
    width: 100%;
    justify-content: center;
    padding: 10px 12px;
    font-size: 11px;
    border-left: none;
    border-right: var(--border-w) solid var(--line);
  }

  .modal-actions .control-cell:last-child {
    border-right: none;
  }

  .lb-body {
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    overflow-x: hidden;
    flex: 1 1 auto;
    min-height: 0;
  }

  .lb-stage {
    align-items: stretch;
    padding: 12px;
    min-height: 0;
    flex: 0 0 auto;
  }

  .lb-figure > img {
    max-height: 55vh;
  }

  .lb-nav {
    top: 150px;
    transform: none;
    width: 34px;
    height: 40px;
    background: rgba(8, 8, 8, 0.78);
  }

  .lb-prev {
    left: 16px;
  }

  .lb-next {
    right: 16px;
  }

  .lb-compare-stage {
    width: 100%;
    max-width: 100%;
    max-height: 52vh;
  }

  .lb-compare-tag {
    top: 8px;
    font-size: 9px;
    padding: 3px 6px;
  }

  .lb-compare-tag-before {
    left: 8px;
  }

  .lb-compare-tag-after {
    right: 8px;
  }

  .lb-transfer {
    max-width: 100%;
    margin-top: 10px;
  }

  .lb-transfer-head {
    padding: 8px 12px;
    font-size: 10px;
  }

  .lb-transfer-list li {
    grid-template-columns: 24px minmax(0, 1fr);
    gap: 8px;
    padding: 9px 12px;
    font-size: 11.5px;
    line-height: 1.45;
  }

  .lb-info {
    padding: 16px 14px 28px;
    flex: 0 0 auto;
  }
}