/* ===========================================================
   Krenar Sinani — site styles
   Colors and fonts live in :root so they're easy to change.
   =========================================================== */
:root {
  --bg: #f5f3ee;          /* warm paper white */
  --surface: #ffffff;
  --ink: #1d1d1b;         /* near-black text */
  --muted: #6b6a64;       /* secondary text */
  --line: #dcd8cf;        /* thin rules / borders */
  --accent: #b5643a;      /* clay orange, from the logo */
  /* Avant Garde Gothic everywhere. If the real ITC Avant Garde is installed on the
     visitor's computer it's used; otherwise the free look-alike TeX Gyre Adventor loads,
     and Century Gothic (on most Windows PCs) is the last backup. */
  --serif: "ITC Avant Garde Gothic", "Avant Garde", "TeXGyreAdventor", "TeX Gyre Adventor", "Century Gothic", "Futura", sans-serif;
  --sans: var(--serif);
  --wrap: 1240px;
  --pad: clamp(20px, 4vw, 48px);
}

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--pad); }

.eyebrow {
  font-size: 12px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 14px;
}
h1, h2, h3 { font-family: var(--serif); font-weight: 400; line-height: 1.12; letter-spacing: -.015em; margin: 0; }
h2 { font-size: clamp(30px, 4vw, 48px); }

/* ---------- Header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 20;
  transition: background .3s, border-color .3s;
  border-bottom: 1px solid transparent;
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 76px; }
.brand { text-decoration: none; display: flex; flex-direction: column; line-height: 1.15; }
.brand-name { font-family: var(--sans); font-size: 19px; font-weight: 700; letter-spacing: .24em; }
.brand-sub { font-size: 10.5px; letter-spacing: .22em; text-transform: uppercase; opacity: .75; }
.nav { display: flex; gap: 34px; }
.nav a { text-decoration: none; font-size: 13px; letter-spacing: .14em; text-transform: uppercase; }
.nav a:hover { color: var(--accent); }
.menu-btn { display: none; background: none; border: 0; font: inherit; font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: inherit; cursor: pointer; padding: 8px 0; }

/* Header sits white-on-photo over the hero, then turns solid on scroll */
.site-header.on-hero { color: #fff; }
.site-header.solid { background: rgba(245, 243, 238, .96); backdrop-filter: blur(6px); border-color: var(--line); color: var(--ink); }

/* ---------- Hero ---------- */
.hero { position: relative; height: 100vh; min-height: 560px; color: #fff; overflow: hidden; }
.hero img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 65% 40%; }
.hero::after { content: ""; position: absolute; inset: 0; background:
  linear-gradient(90deg, rgba(0,0,0,.55) 0%, rgba(0,0,0,.25) 45%, rgba(0,0,0,0) 70%),
  linear-gradient(180deg, rgba(0,0,0,.35) 0%, rgba(0,0,0,0) 25%, rgba(0,0,0,0) 55%, rgba(0,0,0,.5) 100%); }
.hero h1, .hero p { text-shadow: 0 1px 24px rgba(0,0,0,.25); }
.hero-text { position: absolute; z-index: 1; left: 0; right: 0; bottom: clamp(40px, 9vh, 90px); }
.hero h1 { font-size: clamp(38px, 6vw, 80px); max-width: 15ch; }
.hero p { margin: 18px 0 0; max-width: 46ch; font-size: 17px; opacity: .92; }
.hero .eyebrow { color: rgba(255,255,255,.85); }
.hero-caption { position: absolute; z-index: 1; right: var(--pad); bottom: 22px; font-size: 12px; letter-spacing: .08em; opacity: .8; }

/* ---------- Sections ---------- */
section { padding: clamp(80px, 11vw, 140px) 0; }
.section-head { display: flex; justify-content: space-between; align-items: end; gap: 24px; margin-bottom: 48px; flex-wrap: wrap; }
.section-head p { max-width: 42ch; color: var(--muted); margin: 0; }

/* ---------- Project grid ---------- */
.grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 56px 40px; }
.card { text-decoration: none; display: block; }
.card-img { overflow: hidden; aspect-ratio: 4 / 3; background: #e9e6df; }
.card-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s cubic-bezier(.2,.7,.2,1); }
.card-img.drawing img { object-fit: contain; padding: 6%; background: #fff; }
.card:hover .card-img img { transform: scale(1.035); }
.card-meta { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding-top: 16px; }
.card h3 { font-size: 24px; }
.card-meta > span { font-size: 13px; color: var(--muted); text-align: right; white-space: nowrap; }
.card .type { display: block; font-size: 13px; color: var(--muted); margin-top: 2px; }

/* ---------- About ---------- */
.about { background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.about-grid { display: grid; grid-template-columns: 5fr 6fr; gap: clamp(40px, 7vw, 100px); align-items: center; }
.about-img { aspect-ratio: 4 / 5; overflow: hidden; }
.about-img img { width: 100%; height: 100%; object-fit: cover; }
.about-text p { font-size: 17px; color: #3a3935; }
.about-text h2 { margin-bottom: 26px; }
.services { list-style: none; padding: 0; margin: 34px 0 0; display: grid; grid-template-columns: 1fr 1fr; gap: 0 32px; }
.services li { padding: 13px 0; border-top: 1px solid var(--line); font-size: 15px; }
.services li::before { content: "—"; color: var(--accent); margin-right: 10px; }

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(40px, 7vw, 100px); }
.contact-info p { color: var(--muted); max-width: 38ch; }
.contact-list { list-style: none; padding: 0; margin: 34px 0 0; }
.contact-list li { padding: 14px 0; border-top: 1px solid var(--line); }
.contact-list small { display: block; font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.contact-list a { text-decoration: none; font-size: 19px; }
.contact-list a:hover { color: var(--accent); }
form { display: grid; gap: 18px; }
label { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); display: grid; gap: 6px; }
input, textarea, select {
  font: inherit; font-size: 16px; color: var(--ink);
  background: transparent; border: 0; border-bottom: 1px solid #b9b4a9;
  padding: 10px 0; border-radius: 0; text-transform: none; letter-spacing: 0;
}
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--ink); }
textarea { min-height: 130px; resize: vertical; }
.hidden { display: none; }
.btn {
  justify-self: start; margin-top: 8px;
  background: var(--ink); color: #fff; border: 0; cursor: pointer;
  font: inherit; font-size: 13px; letter-spacing: .16em; text-transform: uppercase;
  padding: 16px 34px; text-decoration: none; display: inline-block;
  transition: background .2s;
}
.btn:hover { background: var(--accent); }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding: 34px 0; font-size: 13px; color: var(--muted); }
.site-footer .wrap { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.site-footer a { text-decoration: none; }

/* ---------- Project page ---------- */
.project-head { padding-top: 150px; padding-bottom: 50px; }
.project-head h1 { font-size: clamp(38px, 5.5vw, 72px); }
.back { display: inline-block; margin-bottom: 28px; font-size: 12px; letter-spacing: .16em; text-transform: uppercase; text-decoration: none; color: var(--muted); }
.back:hover { color: var(--accent); }
.facts { display: flex; flex-wrap: wrap; gap: 0; margin: 40px 0 0; border-top: 1px solid var(--line); }
.facts div { padding: 16px 40px 0 0; min-width: 160px; }
.facts dt { font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.facts dd { margin: 4px 0 0; font-size: 16px; }
.project-desc { max-width: 62ch; font-size: 18px; color: #3a3935; margin-top: 34px; }
.project-cover { margin-bottom: 18px; }
.project-cover img { width: 100%; max-height: 88vh; object-fit: cover; cursor: zoom-in; }
.project-cover.drawing img { object-fit: contain; background: #fff; padding: 3%; }
.gallery { columns: 2; column-gap: 18px; padding-bottom: 40px; }
.gallery figure { margin: 0 0 18px; break-inside: avoid; background: #fff; cursor: zoom-in; }
.gallery img { width: 100%; }
.next-project { display: block; text-decoration: none; border-top: 1px solid var(--line); padding: 60px 0 70px; }
.next-project small { font-size: 12px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.next-project span { display: block; font-family: var(--serif); font-size: clamp(30px, 4vw, 54px); }
.next-project:hover span { color: var(--accent); }

/* ---------- Lightbox ---------- */
.lightbox { position: fixed; inset: 0; z-index: 50; background: rgba(18,18,16,.95); display: none; align-items: center; justify-content: center; }
.lightbox.open { display: flex; }
.lightbox img { max-width: 92vw; max-height: 88vh; object-fit: contain; }
.lightbox button { position: absolute; background: none; border: 0; color: #fff; font-size: 34px; cursor: pointer; padding: 20px; opacity: .8; line-height: 1; }
.lightbox button:hover { opacity: 1; }
.lb-close { top: 8px; right: 12px; }
.lb-prev { left: 8px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 8px; top: 50%; transform: translateY(-50%); }
.lb-count { position: absolute; bottom: 20px; left: 0; right: 0; text-align: center; color: rgba(255,255,255,.7); font-size: 13px; letter-spacing: .1em; }

/* ---------- Fade-in on scroll ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .9s ease, transform .9s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ---------- Mobile ---------- */
@media (max-width: 860px) {
  .grid, .about-grid, .contact-grid { grid-template-columns: 1fr; }
  .services { grid-template-columns: 1fr; }
  .gallery { columns: 1; }
  .about-img { aspect-ratio: 4 / 3; }
  .menu-btn { display: block; }
  .nav {
    position: fixed; inset: 76px 0 auto 0; flex-direction: column; gap: 0;
    background: var(--bg); color: var(--ink); border-bottom: 1px solid var(--line);
    padding: 8px var(--pad) 18px; display: none;
  }
  .nav.open { display: flex; }
  .nav a { padding: 14px 0; border-top: 1px solid var(--line); }
  .hero-caption { display: none; }
}

/* ---------- Project photos: big, one after another, just scroll ---------- */
.photos { display: grid; gap: clamp(12px, 2vw, 28px); padding: 0 clamp(12px, 2vw, 32px) 60px; }
.photo { margin: 0; display: flex; justify-content: center; }
.photo img { width: auto; max-width: 100%; max-height: calc(100vh - 40px); object-fit: contain; }


/* Two portrait pictures side by side, same height, filling the row */
.photo-pair {
  margin: 0 auto; width: 100%;
  max-width: calc((100vh - 40px) * var(--r) + clamp(12px, 2vw, 28px));
  display: flex; gap: clamp(12px, 2vw, 28px);
}
.photo-pair img { width: 100%; height: auto; }
@media (max-width: 700px) {
  .photo-pair { flex-direction: column; max-width: none; }
  .photo-pair > div { flex: none !important; }
}

/* ---------- Experience page ---------- */
.text-link { color: var(--accent); text-decoration: none; font-size: 14px; letter-spacing: .06em; }
.text-link:hover { text-decoration: underline; }
.exp-section { padding: 30px 0 90px; }
.table-wrap { overflow-x: auto; }
.ind-table { width: 100%; border-collapse: collapse; font-size: 15px; }
.ind-table th { text-align: left; font-weight: 500; font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); padding: 0 16px 12px 0; }
.ind-table td { padding: 15px 16px 15px 0; border-top: 1px solid var(--line); color: var(--muted); vertical-align: top; }
.ind-table td.pj { color: var(--ink); font-weight: 500; }
.ind-table td.pj a { color: var(--accent); text-decoration: none; }
.ind-table td.pj a:hover { text-decoration: underline; }
.ind-table .area { text-align: right; white-space: nowrap; padding-right: 0; }
.firm { margin-bottom: 54px; }
.firm h3 { font-size: 28px; margin-bottom: 14px; }
.firm h3 span { display: block; font-family: var(--sans); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-top: 6px; }
.exp-list { list-style: none; padding: 0; margin: 0; }
.exp-list li { display: grid; grid-template-columns: 130px 1fr auto; gap: 16px; padding: 14px 0; border-top: 1px solid var(--line); font-size: 15px; }
.exp-list .yr { color: var(--accent); font-size: 13px; letter-spacing: .04em; padding-top: 1px; }
.exp-list .loc { color: var(--muted); text-align: right; }
@media (max-width: 700px) {
  .exp-list li { grid-template-columns: 90px 1fr; }
  .exp-list .loc { grid-column: 2; text-align: left; margin-top: -10px; font-size: 13px; }
  .ind-table th:nth-child(3), .ind-table td:nth-child(3) { display: none; }
}
section[id] { scroll-margin-top: 76px; }
.exp-list .pj a, .firm h3 a { color: inherit; text-decoration: none; border-bottom: 1px solid transparent; transition: color .2s, border-color .2s; }
.exp-list .pj a { color: var(--ink); border-bottom-color: var(--line); }
.exp-list .pj a:hover, .firm h3 a:hover { color: var(--accent); border-bottom-color: var(--accent); }
.exp-list .ext { font-size: 12px; color: var(--accent); }
