/* Studio PLN */

:root {
  --text: #000;
  --muted: #555;
  --bg: #fff;
  --line: #000;
  --gutter: 62px;
  --max: 1320px;
}

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

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Montserrat", Helvetica, Arial, sans-serif;
  font-size: 16px;
  font-weight: 300;
  line-height: 25px;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: inherit;
}

h1,
h2,
h3 {
  font-weight: 400;
  letter-spacing: 1px;
  margin: 0;
}

h1 {
  font-size: 3em;
  line-height: 1.2;
  margin-bottom: 25px;
}

h2 {
  font-size: 2.5em;
  line-height: 1.2;
  margin-bottom: 6px;
}

p {
  margin: 0 0 28px;
}

.container {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* Header */

.site-header {
  padding-top: 40px;
}

.site-header .container {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.logo img {
  width: 100px;
  height: 100px;
}

.nav ul {
  display: flex;
  gap: 34px;
  margin: 0;
  padding: 23px 0 0;
  list-style: none;
}

.nav a {
  font-family: "Poppins", Helvetica, Arial, sans-serif;
  font-size: 12px;
  font-weight: 500;
  line-height: 12px;
  letter-spacing: 1px;
  text-transform: uppercase;
  text-decoration: none;
}

.nav a:hover,
.nav a[aria-current="page"] {
  text-decoration: line-through;
}

.nav-toggle {
  display: none;
  margin-top: 30px;
  padding: 8px;
  border: 0;
  background: none;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 26px;
  height: 1.5px;
  margin: 6px 0;
  background: var(--text);
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.nav-open .nav-toggle span:nth-child(1) {
  transform: translateY(7.5px) rotate(45deg);
}

.nav-open .nav-toggle span:nth-child(2) {
  opacity: 0;
}

.nav-open .nav-toggle span:nth-child(3) {
  transform: translateY(-7.5px) rotate(-45deg);
}

/* Main */

main {
  padding: 40px 0 100px;
}

.intro {
  margin-bottom: 40px;
}

.section-title {
  margin: 20px 0 50px;
}

.more {
  margin-top: 60px;
  text-align: center;
}

.button {
  display: inline-block;
  padding: 5px 20px;
  border: 0;
  border-radius: 1.55em;
  background: var(--text);
  color: var(--bg);
  font-family: "Poppins", Helvetica, Arial, sans-serif;
  font-size: 0.9em;
  font-weight: 400;
  line-height: 25px;
  text-decoration: none;
  cursor: pointer;
}

.button:hover {
  background: #333;
}

/* Image grids */

.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--gap, 15px);
}

.grid--wide {
  --gap: 70px;
}

.tile {
  display: block;
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: #f3f3f1;
}

.tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease, opacity 0.4s ease;
}

.tile:hover img {
  transform: scale(1.04);
}

.tile-caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 14px 18px;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.45));
  color: #fff;
  font-size: 0.9em;
  letter-spacing: 1px;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.tile:hover .tile-caption,
.tile:focus-visible .tile-caption {
  opacity: 1;
}

/* Masonry: natural image ratios in columns */
.grid--masonry {
  display: block;
  columns: 3;
  column-gap: var(--gap, 15px);
}

.grid--masonry .tile {
  aspect-ratio: auto;
  margin-bottom: var(--gap, 15px);
  break-inside: avoid;
}

.js .is-more {
  display: none;
}

/* Category cards (Projects, Furniture, Architecture) */

.cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 60px;
}

.card {
  display: block;
  text-decoration: none;
}

.card h2 {
  margin-bottom: 6px;
}

.card hr {
  height: 0;
  margin: 0 0 30px;
  border: 0;
  border-top: 1px solid var(--line);
  width: 100px;
  transition: width 0.4s ease;
}

.card:hover hr {
  width: 100%;
}

.card .tile {
  aspect-ratio: 2 / 3;
  max-width: 460px;
}

.back {
  display: inline-block;
  margin-bottom: 30px;
  font-family: "Poppins", Helvetica, Arial, sans-serif;
  font-size: 12px;
  letter-spacing: 1px;
  text-transform: uppercase;
  text-decoration: none;
}

.back:hover {
  text-decoration: line-through;
}

/* Contact */

.contact {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 60px;
}

.contact h2 {
  margin-top: 10px;
}

.contact a {
  text-decoration: none;
}

.contact a:hover {
  text-decoration: underline;
}

.copy-row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.copy {
  display: inline-flex;
  padding: 4px;
  border: 0;
  background: none;
  color: var(--text);
  cursor: pointer;
}

.copy svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
}

.copy:hover {
  color: var(--muted);
}

.copy-status {
  font-family: "Poppins", Helvetica, Arial, sans-serif;
  font-size: 0.8em;
  color: var(--muted);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.copy-status.is-visible {
  opacity: 1;
}

.form {
  max-width: 340px;
}

.form label {
  display: block;
  margin-bottom: 20px;
  font-family: "Poppins", Helvetica, Arial, sans-serif;
  font-size: 0.9em;
  font-weight: 400;
}

.form input,
.form textarea {
  display: block;
  width: 100%;
  margin-top: 4px;
  padding: 6px 8px;
  border: 1px solid #777;
  border-radius: 0;
  background: var(--bg);
  color: var(--text);
  font: inherit;
}

.form textarea {
  min-height: 160px;
  resize: vertical;
}

.form input:focus,
.form textarea:focus {
  outline: 1px solid var(--text);
  outline-offset: 0;
}

.form-note {
  margin-top: 16px;
  font-size: 0.85em;
  color: var(--muted);
}

/* Footer */

.site-footer {
  padding: 40px 0 50px;
}

.site-footer .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  font-family: "Poppins", Helvetica, Arial, sans-serif;
  font-size: 12px;
}

.site-footer a {
  display: inline-flex;
  text-decoration: none;
}

.site-footer a:hover {
  text-decoration: underline;
}

.site-footer svg {
  width: 18px;
  height: 18px;
}

/* Lightbox */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.97);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s;
}

.lightbox.is-open {
  opacity: 1;
  visibility: visible;
}

.lightbox img {
  max-width: calc(100vw - 160px);
  max-height: calc(100vh - 120px);
  width: auto;
  height: auto;
  object-fit: contain;
  user-select: none;
}

.lightbox button {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--text);
  cursor: pointer;
}

.lightbox button svg {
  width: 26px;
  height: 26px;
  stroke: currentColor;
  stroke-width: 1.2;
  fill: none;
}

.lightbox-close {
  top: 16px;
  right: 16px;
}

.lightbox-prev {
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
}

.lightbox-next {
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
}

.lightbox-count {
  position: absolute;
  top: 32px;
  left: 32px;
  font-family: "Poppins", Helvetica, Arial, sans-serif;
  font-size: 12px;
  letter-spacing: 1px;
}

.lightbox.is-single .lightbox-prev,
.lightbox.is-single .lightbox-next,
.lightbox.is-single .lightbox-count {
  display: none;
}

/* Responsive */

@media (max-width: 991px) {
  :root {
    --gutter: 32px;
  }

  .grid--wide {
    --gap: 30px;
  }

  .contact {
    grid-template-columns: 1fr;
    gap: 20px;
  }
}

@media (max-width: 767px) {
  :root {
    --gutter: 20px;
  }

  h1 {
    font-size: 2.2em;
  }

  h2 {
    font-size: 1.8em;
  }

  .site-header {
    padding-top: 24px;
  }

  .logo img {
    width: 76px;
    height: 76px;
  }

  .nav-toggle {
    display: block;
    margin-top: 18px;
  }

  .nav {
    position: fixed;
    inset: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s;
  }

  .nav-open .nav {
    opacity: 1;
    visibility: visible;
  }

  .nav ul {
    flex-direction: column;
    align-items: center;
    gap: 34px;
    padding: 0;
  }

  .nav a {
    font-size: 16px;
  }

  .nav-toggle {
    position: relative;
    z-index: 60;
  }

  .grid,
  .grid--wide {
    grid-template-columns: repeat(2, 1fr);
    --gap: 12px;
  }

  .grid--masonry {
    columns: 2;
  }

  .cards {
    grid-template-columns: 1fr;
    gap: 50px;
  }

  .lightbox img {
    max-width: 100vw;
    max-height: calc(100vh - 140px);
  }

  .lightbox-prev,
  .lightbox-next {
    top: auto;
    bottom: 16px;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
  }
}
