/* ═══════════════════════════════════════════════
   _shared.css — Junaid Gul · Portfolio BUT GEA
   ═══════════════════════════════════════════════ */

/* ── TOKENS ──────────────────────────────────── */
:root {
  --serif:     'Instrument Serif', Georgia, serif;
  --sans:      'Inter', system-ui, sans-serif;

  /* Palette naturelle : encre sombre / papier chaud */
  --ink:       #1a1a18;
  --ink2:      #3d3d38;
  --ink3:      #8a8a82;
  --paper:     #f6f4ee;
  --paper2:    #efecea;
  --panel:     #ffffff;
  --line:      #e2dfd8;
  --line2:     #ede9e3;

  /* Accent vert forêt */
  --accent:      #1f5b50;
  --accent2:     #a8d5c8;
  --accent-soft: rgba(31, 91, 80, .08);

  /* Layout */
  --max:   1300px;
  --pad-x: clamp(1.3rem, 5vw, 3rem);
}

/* ── RESET ───────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
body {
  font-family: var(--sans);
  background: var(--paper);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.6;
}
img { display: block; max-width: 100%; }
a { color: inherit; }
button { font-family: inherit; cursor: pointer; }

/* ── NAVIGATION ──────────────────────────────── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--pad-x);
  height: 64px;
  background: rgba(246, 244, 238, .88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.logo {
  font-family: var(--serif);
  font-size: 1.2rem;
  font-style: italic;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -.01em;
  white-space: nowrap;
}

nav ul {
  display: flex;
  align-items: center;
  gap: .2rem;
  list-style: none;
}

nav ul a {
  display: block;
  padding: .4rem .8rem;
  font-size: .82rem;
  font-weight: 500;
  color: var(--ink2);
  text-decoration: none;
  border-radius: 8px;
  transition: color .18s, background .18s;
  white-space: nowrap;
}
nav ul a:hover   { color: var(--ink); background: var(--paper2); }
nav ul a.active  { color: var(--accent); background: var(--accent-soft); }

.nav-cta {
  background: var(--ink) !important;
  color: var(--paper) !important;
  border-radius: 100px !important;
  padding: .45rem 1.1rem !important;
  font-size: .8rem !important;
  transition: background .18s !important;
}
.nav-cta:hover { background: var(--accent) !important; }

@media (max-width: 760px) {
  nav ul a:not(.nav-cta) { display: none; }
  .nav-cta { display: block; }
}

/* ── SIDE NAVIGATION (← / →) ─────────────────── */
.snav {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  z-index: 90;
  display: flex;
  align-items: center;
  gap: .7rem;
  padding: .9rem 1rem;
  background: rgba(246, 244, 238, .85);
  backdrop-filter: blur(10px);
  border: 1px solid var(--line);
  text-decoration: none;
  color: var(--ink);
  transition: border-color .2s, background .2s, transform .2s;
}
.snav:hover { border-color: var(--accent); background: var(--panel); transform: translateY(-50%) scale(1.03); }

.snav-prev { left: 0; border-radius: 0 12px 12px 0; border-left: none; }
.snav-next { right: 0; border-radius: 12px 0 0 12px; border-right: none; }

.snav-ic {
  font-size: 1.3rem;
  color: var(--accent);
  line-height: 1;
}
.snav-lab {
  display: flex;
  flex-direction: column;
  gap: .1rem;
  max-width: 110px;
}
.snav-tag { font-size: .68rem; color: var(--ink3); }
.snav-lab > span:last-child { font-size: .8rem; font-weight: 600; line-height: 1.2; }

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

/* ── PAGE HEADER ─────────────────────────────── */
.phead {
  padding: 9rem var(--pad-x) 4rem;
  max-width: var(--max);
  margin: 0 auto;
}

.phead-eyebrow {
  font-size: .75rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 1.2rem;
  display: flex;
  align-items: center;
  gap: .7rem;
}
.phead-eyebrow::before {
  content: '';
  width: 26px; height: 1px;
  background: var(--accent);
}

.phead-title {
  font-family: var(--serif);
  font-size: clamp(3rem, 8vw, 6.5rem);
  line-height: .95;
  letter-spacing: -.02em;
  font-weight: 400;
  margin-bottom: 1.5rem;
}
.phead-title em {
  font-style: italic;
  color: var(--accent);
}

.phead-sub {
  font-size: 1rem;
  color: var(--ink2);
  line-height: 1.75;
  max-width: 58ch;
}

/* ── SECTIONS ────────────────────────────────── */
.section {
  padding: 5rem var(--pad-x);
  max-width: var(--max);
  margin: 0 auto;
  border-top: 1px solid var(--line);
}
.section:first-of-type { border-top: none; }

.sec-label {
  font-size: .72rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: .9rem;
}

.sec-title {
  font-family: var(--serif);
  font-size: clamp(2rem, 4vw, 3.2rem);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -.015em;
  margin-bottom: 1.2rem;
}
.sec-title em { font-style: italic; color: var(--accent); }

.sec-intro {
  font-size: .96rem;
  color: var(--ink2);
  line-height: 1.8;
  max-width: 62ch;
  margin-bottom: 3rem;
}

/* ── TAGS ────────────────────────────────────── */
.tags { display: flex; flex-wrap: wrap; gap: .4rem; }
.tag {
  font-size: .72rem;
  padding: .22rem .75rem;
  border-radius: 100px;
  background: var(--paper2);
  color: var(--ink2);
  border: 1px solid var(--line);
  font-weight: 500;
}
.tag.accent {
  background: var(--accent-soft);
  color: var(--accent);
  border-color: rgba(31, 91, 80, .25);
}

/* ── UPLOAD WIDGET ───────────────────────────── */
.upload {
  display: flex;
  align-items: center;
  gap: .8rem;
  padding: .9rem 1.1rem;
  border: 1.5px dashed var(--line);
  border-radius: 10px;
  cursor: pointer;
  transition: border-color .2s, background .2s;
  background: var(--paper2);
}
.upload:hover { border-color: var(--accent); background: var(--accent-soft); }

.u-ic { font-size: 1.1rem; }
.u-lab { font-size: .84rem; font-weight: 600; color: var(--ink2); }
.u-sub { font-size: .74rem; color: var(--ink3); margin-left: auto; }

.flist { margin-top: .6rem; display: flex; flex-direction: column; gap: .4rem; }
.fitem {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: .8rem;
  padding: .5rem .8rem;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  gap: .8rem;
}
.fitem a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 500;
  white-space: nowrap;
}
.fitem a:hover { text-decoration: underline; }

/* ── BOTTOM PAGE NAV ─────────────────────────── */
.pnav {
  display: flex;
  justify-content: space-between;
  align-items: stretch;
  border-top: 1px solid var(--line);
  max-width: var(--max);
  margin: 0 auto;
}

.pnav a {
  display: flex;
  flex-direction: column;
  gap: .25rem;
  padding: 2rem var(--pad-x);
  text-decoration: none;
  color: var(--ink);
  flex: 1;
  transition: background .18s;
}
.pnav a:hover { background: var(--paper2); }
.pnav a + a { border-left: 1px solid var(--line); }

.pn-dir {
  font-size: .72rem;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--ink3);
  font-weight: 500;
}
.pn-name {
  font-family: var(--serif);
  font-size: 1.3rem;
  font-style: italic;
  color: var(--accent);
}

/* ── FOOTER ──────────────────────────────────── */
footer {
  display: flex;
  flex-direction: column;
  gap: .25rem;
  padding: 2rem var(--pad-x);
  border-top: 1px solid var(--line);
  font-size: .76rem;
  color: var(--ink3);
  max-width: var(--max);
  margin: 0 auto;
}

/* ── SCROLL REVEAL ───────────────────────────── */
.rev {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .55s ease, transform .55s ease;
}
.rev.in {
  opacity: 1;
  transform: none;
}

/* ── SCROLLBAR ───────────────────────────────── */
::-webkit-scrollbar       { width: 6px; }
::-webkit-scrollbar-track { background: var(--paper2); }
::-webkit-scrollbar-thumb { background: var(--line); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--ink3); }

/* ── SELECTION ───────────────────────────────── */
::selection { background: var(--accent); color: var(--paper); }
