/* ============================================================
   JACOB KORNFELD — Portfolio
   Pavel / RIER inspired system
   style.css
   ============================================================ */

/* --- Reset & Base ------------------------------------------ */

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

:root {
  --white: #ffffff;
  --black: #000000;
  --soft-black: #111111;
  --muted: #777777;
  --border: #dddddd;

  --font: Arial, Helvetica, sans-serif;
  --serif: Georgia, "Times New Roman", Times, serif;

  --text-small: 14px;
  --text-medium: 18px;
  --text-large: clamp(34px, 4.6vw, 68px);

  --sidebar-w: 168px;
  --page-pad: 8px;
  --image-col: 570px;

  --transition: 0.2s ease;
}

html {
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font);
  background: var(--white);
  color: var(--black);
  min-height: 100vh;
  overflow-x: hidden;
  opacity: 0;
  animation: fadeIn 0.35s ease forwards;
}

@keyframes fadeIn {
  to { opacity: 1; }
}

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

a:hover {
  text-decoration: underline;
}

img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
}

/* ============================================================
   SHARED TYPE
   ============================================================ */

p,
li,
a,
span,
td,
th {
  font-size: var(--text-small);
  line-height: 1.22;
  letter-spacing: -0.01em;
  font-weight: 400;
}

em,
i {
  font-style: italic;
}

/* ============================================================
   HOMEPAGE LAYOUT
   ============================================================ */

.home-layout {
  display: grid;
  grid-template-columns: var(--sidebar-w) 1fr;
  min-height: 100vh;
  width: 100%;
  background: var(--white);
}

/* left homepage column */
.left-col {
  width: var(--sidebar-w);
  height: 100vh;
  position: fixed;
  left: 0;
  top: 0;
  background: var(--white);
  padding: 14px 10px;
  z-index: 20;
}

/* name */
.name-vertical {
  position: absolute;
  left: 10px;
  top: 14px;
  writing-mode: horizontal-tb;
  transform: none;
  font-size: var(--text-small);
  letter-spacing: -0.01em;
  text-transform: none;
  color: var(--black);
  user-select: none;
}

/* primary nav */
.primary-nav {
  position: absolute;
  left: 10px;
  top: 50%;
  right: auto;
  transform: translateY(-50%);
  text-align: left;
}

.primary-nav ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.primary-nav a {
  font-size: var(--text-small);
  letter-spacing: -0.01em;
  color: var(--black);
  transition: none;
}

.primary-nav a:hover,
.primary-nav a.active {
  color: var(--black);
  text-decoration: underline;
  font-weight: 400;
}

/* footer nav */
.footer-nav {
  position: absolute;
  bottom: 28px;
  left: 10px;
}

.footer-nav a {
  display: block;
  font-size: var(--text-small);
  letter-spacing: -0.01em;
  color: var(--black);
  line-height: 1.25;
}

.footer-nav a:hover {
  color: var(--black);
  text-decoration: underline;
}

.footer-nav .copyright {
  display: block;
  margin-top: 26px;
  font-size: var(--text-small);
  letter-spacing: -0.01em;
  color: var(--black);
}

/* homepage image side */
.right-col {
  grid-column: 2;
  min-height: 100vh;
  width: 100%;
  background: var(--white);
  overflow: hidden;
  position: relative;
}

.hero-image {
  width: 100%;
  height: 100vh;
  object-fit: cover;
  filter: none;
  transition: none;
}

.right-col:hover .hero-image {
  filter: none;
}

.image-caption {
  position: absolute;
  bottom: 10px;
  right: 10px;
  font-size: var(--text-small);
  letter-spacing: -0.01em;
  color: var(--black);
  text-transform: none;
}

/* ============================================================
   INNER PAGES — SHARED SHELL
   ============================================================ */

.page-layout {
  display: block;
  min-height: 100vh;
  width: 100%;
  background: var(--white);
}

/* fixed sidebar */
.sidebar {
  position: fixed;
  left: 0;
  top: 0;
  width: var(--sidebar-w);
  min-width: var(--sidebar-w);
  height: 100vh;
  min-height: 100vh;
  background: var(--white);
  border-right: none;
  padding: 14px 10px;
  z-index: 20;
}

.sidebar .name-vertical {
  position: absolute;
  left: 10px;
  top: 14px;
  writing-mode: horizontal-tb;
  transform: none;
  font-size: var(--text-small);
  letter-spacing: -0.01em;
  text-transform: none;
  color: var(--black);
}

.sidebar .primary-nav {
  position: absolute;
  left: 10px;
  top: 50%;
  right: auto;
  transform: translateY(-50%);
  text-align: left;
}

.sidebar .footer-nav {
  position: absolute;
  left: 10px;
  bottom: 28px;
}

/* main content */
.content-area {
  margin-left: var(--sidebar-w);
  min-height: 100vh;
  padding: 14px 10px 90px 0;
  background: var(--white);
}

/* page header */
.page-header {
  margin: 0 0 72px 0;
  padding: 0;
  border-bottom: none;
}

.page-title {
  font-size: var(--text-small);
  letter-spacing: -0.01em;
  text-transform: none;
  color: var(--black);
}

/* ============================================================
   CATEGORY PAGES
   fashion, art, objects
   ============================================================ */

.category-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(260px, 420px));
  gap: 90px 72px;
  align-items: start;
  padding-right: 40px;
}

.project-item {
  cursor: default;
}

.project-thumb {
  width: 100%;
  aspect-ratio: auto;
  overflow: visible;
  background: transparent;
  margin-bottom: 8px;
}

.project-thumb img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
  filter: none;
  transition: none;
}

.project-item:hover .project-thumb img {
  filter: none;
  transform: none;
}

.thumb-placeholder {
  width: 100%;
  min-height: 320px;
  background: transparent;
  border: 1px solid var(--border);
  display: flex;
  align-items: flex-start;
  justify-content: flex-start;
  padding: 8px;
  font-size: var(--text-small);
  letter-spacing: -0.01em;
  text-transform: none;
  color: var(--black);
}

.project-meta {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 18px;
  margin-bottom: 2px;
}

.project-name {
  font-size: var(--text-small);
  letter-spacing: -0.01em;
  color: var(--black);
  font-weight: 400;
}

.project-year {
  font-size: var(--text-small);
  letter-spacing: -0.01em;
  color: var(--black);
}

.project-desc {
  max-width: 360px;
  font-size: var(--text-small);
  letter-spacing: -0.01em;
  color: var(--black);
  line-height: 1.25;
}

/* ============================================================
   ART / GRAPHIC DESIGN PAGE — CLICK IMAGE LIGHTBOX
   ============================================================ */

   body.art-page .project-thumb {
    cursor: zoom-in;
  }
  
  body.art-page .lightbox-image {
    cursor: zoom-in;
  }
  
  .image-lightbox {
    position: fixed;
    inset: 0;
    background: rgba(255, 255, 255, 0.96);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 48px;
    cursor: zoom-out;
  }
  
  .image-lightbox.active {
    display: flex;
  }
  
  .image-lightbox img {
    display: block;
    max-width: 92vw;
    max-height: 90vh;
    width: auto;
    height: auto;
    object-fit: contain;
    cursor: default;
  }
  
  .image-lightbox-close {
    position: fixed;
    top: 14px;
    right: 14px;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 14px;
    letter-spacing: -0.01em;
    color: #000;
    cursor: pointer;
    z-index: 10000;
  }
  
  .image-lightbox-close:hover {
    text-decoration: underline;
  }
  
  .image-lightbox-caption {
    position: fixed;
    left: 14px;
    bottom: 14px;
    max-width: 420px;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 14px;
    letter-spacing: -0.01em;
    line-height: 1.25;
    color: #000;
  }
  
  @media (max-width: 700px) {
    .image-lightbox {
      padding: 24px 12px;
    }
  
    .image-lightbox img {
      max-width: 96vw;
      max-height: 82vh;
    }
  
    .image-lightbox-caption {
      left: 12px;
      bottom: 12px;
      max-width: calc(100vw - 24px);
    }
  }
/* ============================================================
   WORKS PAGE — master index
   ============================================================ */

.works-table {
  width: calc(100vw - var(--sidebar-w) - 20px);
  border-collapse: collapse;
}

.works-table thead tr {
  border-bottom: none;
}

.works-table th {
  font-size: var(--text-small);
  letter-spacing: -0.01em;
  text-transform: none;
  color: var(--black);
  font-weight: 400;
  padding: 0 0 42px 0;
  text-align: left;
}

.works-table th:last-child {
  text-align: left;
}

.works-table tbody tr {
  border-bottom: none;
  cursor: default;
  transition: none;
  position: relative;
}

.works-table tbody tr:hover {
  background: transparent;
}

.works-table tbody tr:hover .work-title {
  color: var(--black);
  text-decoration: underline;
}

.works-table td {
  padding: 0 60px 34px 0;
  vertical-align: top;
}

.works-table td:last-child {
  text-align: left;
  padding-right: 0;
}

.work-title,
.work-cat,
.work-type,
.work-year {
  font-size: var(--text-small);
  letter-spacing: -0.01em;
  color: var(--black);
  font-weight: 400;
  line-height: 1.22;
  padding-right: 0;
}

/* Hover image preview */
.work-preview {
  position: fixed;
  pointer-events: none;
  z-index: 100;
  width: 260px;
  height: auto;
  overflow: hidden;
  opacity: 0;
  transition: opacity 0.15s ease;
  background: var(--white);
}

.work-preview img {
  width: 100%;
  height: auto;
  object-fit: contain;
  filter: none;
}

.work-preview.visible {
  opacity: 1;
}

/* ============================================================
   INFORMATION PAGE
   Pavel / RIER editorial info layout
   ============================================================ */

.info-layout {
  max-width: none;
  width: calc(100vw - var(--sidebar-w) - 20px);
  display: grid;
  grid-template-columns: minmax(360px, 58vw) minmax(180px, 300px);
  column-gap: 80px;
  align-items: start;
}

/* Big bio paragraph if used */
.info-body {
  font-family: var(--serif);
  font-size: clamp(30px, 3.8vw, 58px);
  line-height: 1.08;
  letter-spacing: -0.035em;
  color: var(--black);
  max-width: 1100px;
}

.info-body p + p {
  margin-top: 0.8em;
}

/* Info sections */
.info-section {
  margin-bottom: 64px;
}

.info-section:first-child {
  grid-column: 1 / -1;
  margin-bottom: 90px;
}

.info-label {
  font-size: 12px;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  color: var(--black);
  margin-bottom: 12px;
}

.info-list {
  list-style: none;
}

.info-list li {
  font-size: var(--text-small);
  letter-spacing: -0.01em;
  color: var(--black);
  line-height: 1.22;
  margin-bottom: 2px;
}

.info-list li span {
  color: var(--black);
  margin-right: 0;
  display: block;
  min-width: 0;
}

.contact-line {
  font-size: var(--text-small);
  letter-spacing: -0.01em;
  color: var(--black);
  line-height: 1.25;
}

.contact-line a {
  border-bottom: 1px solid var(--black);
  transition: none;
}

.contact-line a:hover {
  color: var(--black);
  border-color: var(--black);
}

/* ============================================================
   PHOTOGRAPHY PAGE — Pavel Golik style archive
   works with photography.html using .photo-sidebar / .photo-content
   ============================================================ */

body.photography-page {
  margin: 0;
  background: var(--white);
  color: var(--black);
  font-family: var(--font);
  font-size: var(--text-small);
  line-height: 1.25;
  overflow-x: hidden;
}

/* fixed left sidebar */
body.photography-page .photo-sidebar {
  position: fixed;
  left: 0;
  top: 0;
  width: var(--sidebar-w);
  height: 100vh;
  padding: 14px 10px;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: var(--white);
  z-index: 20;
}

/* sidebar typography */
body.photography-page .photo-sidebar a,
body.photography-page .photo-sidebar span,
body.photography-page .go-back {
  color: var(--black);
  text-decoration: none;
  font-size: var(--text-small);
  letter-spacing: -0.01em;
  text-transform: none;
  font-weight: 400;
}

body.photography-page .photo-sidebar a:hover,
body.photography-page .go-back:hover {
  text-decoration: underline;
}

body.photography-page .site-name {
  display: inline-block;
}

body.photography-page .photo-sidebar-middle {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

body.photography-page .photo-sidebar-bottom {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

body.photography-page .go-back {
  position: fixed;
  top: 14px;
  right: 10px;
  z-index: 30;
}

/* main image column */
body.photography-page .photo-content {
  margin-left: var(--sidebar-w);
  min-height: 100vh;
  background: var(--white);
}

body.photography-page .photo-stack {
  width: var(--image-col);
  padding: 0 0 90px 0;
}

body.photography-page .photo-entry {
  width: var(--image-col);
  margin: 0 0 60px 0;
}

body.photography-page .photo-entry img {
  display: block;
  width: var(--image-col);
  height: auto;
  object-fit: contain;
}

/* ============================================================
   OPTIONAL — RIER STYLE LARGE TEXT PAGE
   Use by adding class="large-text-page" to body
   ============================================================ */

body.large-text-page .content-area {
  padding-top: 76px;
}

body.large-text-page .page-header {
  position: fixed;
  top: 8px;
  left: 50%;
  transform: translateX(-50%);
  margin: 0;
  z-index: 40;
}

body.large-text-page .page-title {
  font-family: var(--serif);
  font-size: 22px;
  letter-spacing: -0.03em;
}

body.large-text-page .info-body,
body.large-text-page .large-copy {
  font-family: var(--serif);
  font-size: clamp(34px, 4vw, 68px);
  line-height: 1.08;
  letter-spacing: -0.04em;
  max-width: 1320px;
}

/* ============================================================
   RESPONSIVE — TABLET
   ============================================================ */

@media (max-width: 1024px) {
  :root {
    --sidebar-w: 150px;
    --image-col: 560px;
  }

  .category-grid {
    grid-template-columns: repeat(2, minmax(220px, 1fr));
    gap: 72px 36px;
    padding-right: 24px;
  }

  .info-layout {
    grid-template-columns: 1fr;
    row-gap: 50px;
  }

  .info-section:first-child {
    margin-bottom: 40px;
  }
}

/* ============================================================
   RESPONSIVE — MOBILE
   ============================================================ */

@media (max-width: 700px) {

  :root {
    --sidebar-w: 100%;
    --image-col: 100%;
  }

  body {
    overflow-x: hidden;
  }

  /* homepage */
  .home-layout {
    display: block;
    min-height: 100vh;
  }

  .left-col {
    position: relative;
    width: 100%;
    height: auto;
    min-height: 180px;
    padding: 12px;
  }

  .name-vertical {
    position: static;
    writing-mode: horizontal-tb;
    transform: none;
    display: block;
    margin-bottom: 44px;
  }

  .primary-nav {
    position: static;
    transform: none;
    text-align: left;
    margin-bottom: 44px;
  }

  .primary-nav ul {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 8px 18px;
  }

  .footer-nav {
    position: static;
    display: flex;
    gap: 18px;
    align-items: center;
  }

  .footer-nav .copyright {
    margin-top: 0;
  }

  .right-col {
    min-height: auto;
    height: auto;
  }

  .hero-image {
    width: 100%;
    height: auto;
  }

  /* inner pages */
  .page-layout {
    display: block;
  }

  .sidebar {
    position: relative;
    width: 100%;
    min-width: 100%;
    height: auto;
    min-height: 180px;
    padding: 12px;
  }

  .sidebar .name-vertical {
    position: static;
    writing-mode: horizontal-tb;
    transform: none;
    display: block;
    margin-bottom: 44px;
  }

  .sidebar .primary-nav {
    position: static;
    transform: none;
    text-align: left;
    margin-bottom: 44px;
  }

  .sidebar .primary-nav ul {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 8px 18px;
  }

  .sidebar .footer-nav {
    position: static;
    display: flex;
    gap: 18px;
    align-items: center;
  }

  .sidebar .footer-nav .copyright {
    margin-top: 0;
  }

  .content-area {
    margin-left: 0;
    padding: 12px 12px 70px 12px;
  }

  .page-header {
    margin-bottom: 44px;
  }

  .category-grid {
    grid-template-columns: 1fr;
    gap: 54px;
    padding-right: 0;
  }

  .project-desc {
    max-width: none;
  }

  .works-table {
    width: 100%;
  }

  .works-table thead {
    display: none;
  }

  .works-table,
  .works-table tbody,
  .works-table tr,
  .works-table td {
    display: block;
    width: 100%;
  }

  .works-table tr {
    margin-bottom: 34px;
  }

  .works-table td {
    padding: 0 0 2px 0;
  }

  .works-table td:last-child {
    text-align: left;
  }

  .info-layout {
    width: 100%;
    display: block;
  }

  .info-body {
    font-size: clamp(30px, 9vw, 46px);
    line-height: 1.08;
  }

  .info-section {
    margin-bottom: 48px;
  }

  /* photography mobile */
  body.photography-page .photo-sidebar {
    position: relative;
    width: 100%;
    height: auto;
    padding: 12px;
    gap: 44px;
  }

  body.photography-page .photo-sidebar-middle,
  body.photography-page .photo-sidebar-bottom {
    margin: 0;
  }

  body.photography-page .go-back {
    position: absolute;
    top: 12px;
    right: 12px;
  }

  body.photography-page .photo-content {
    margin-left: 0;
  }

  body.photography-page .photo-stack {
    width: 100%;
    padding: 0 12px 60px 12px;
  }

  body.photography-page .photo-entry {
    width: 100%;
    margin-bottom: 45px;
  }

  body.photography-page .photo-entry img {
    width: 100%;
    height: auto;
  }

}