:root {
  --night: #070b2a;
  --panel: rgba(10, 18, 70, .72);
  --sky: #2b6fd6;
  --glow: #9fd3ff;
  --gold: #f2c75c;
  --rose: #ff8fb1;
  --muted: #6f86c9;
  --text: #dfeaff;
  --serif: "Cinzel", Georgia, serif;
}
*, ::before, ::after {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  scroll-padding-top: env(safe-area-inset-top, 0px);
  padding: env(safe-area-inset-top, 0px) 0 env(safe-area-inset-bottom, 0px);
}
body {
  margin: 0;
  background: var(--night) url("photos/fond.png") center / cover no-repeat fixed;
  color: var(--text);
  font: 15px/1.7 "JetBrains Mono", ui-monospace, Menlo, Consolas, monospace;
  overflow-x: hidden;
}
.sprite {
  position: absolute;
  width: 0;
  height: 0;
}
.k { color: var(--rose); }
.s { color: var(--gold); }
.f { color: var(--glow); }
.c { color: var(--muted); }
h1 {
  margin: 0 0 .6rem;
  font-family: var(--serif);
  font-size: clamp(2.2rem, 6vw, 3.6rem);
  letter-spacing: .04em;
  color: #fff;
  text-shadow: 0 0 26px var(--sky);
}
h2 {
  margin: 0 0 .3rem;
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--gold);
}
h2.title {
  font-family: var(--serif);
  letter-spacing: .06em;
}
.sub {
  margin: 0 0 1.8rem;
  color: var(--muted);
}
pre {
  margin: 0;
  font: inherit;
  white-space: pre-wrap;
  word-break: break-word;
}
section {
  max-width: 1000px;
  margin: 0 auto;
  padding: 3.5rem 1.2rem;
}
footer {
  padding: 2rem 1rem 3rem;
  text-align: center;
  font-size: .85rem;
  color: var(--muted);
}
.btn {
  display: inline-block;
  padding: .7rem 1.6rem;
  border: 1px solid var(--gold);
  border-radius: 6px;
  background: none;
  color: var(--gold);
  font: inherit;
  text-decoration: none;
  cursor: pointer;
}
.btn:hover,
.btn:focus-visible {
  background: var(--gold);
  color: var(--night);
  box-shadow: 0 0 24px var(--gold);
  outline: none;
}
.cmd {
  display: inline-block;
  margin-top: 1rem;
  padding-bottom: 2px;
  border-bottom: 1px solid transparent;
  color: var(--gold);
  font-size: .9rem;
  text-decoration: none;
}
.cmd:hover,
.cmd:focus-visible {
  border-bottom-color: var(--gold);
}
.cmd:focus-visible {
  outline: 2px solid var(--glow);
  outline-offset: 4px;
}
.win {
  overflow: hidden;
  background: var(--panel);
  border: 1px solid rgba(159, 211, 255, .3);
  border-radius: 10px;
  backdrop-filter: blur(8px);
  box-shadow: 0 0 40px rgba(43, 111, 214, .25);
}
.bar {
  display: flex;
  align-items: center;
  gap: .45rem;
  padding: .55rem .9rem;
  background: rgba(7, 11, 42, .8);
  border-bottom: 1px solid rgba(159, 211, 255, .2);
  font-size: .8rem;
  color: var(--muted);
}
.bar i {
  display: block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.bar i:nth-child(1) { background: var(--rose); }
.bar i:nth-child(2) { background: var(--gold); }
.bar i:nth-child(3) { background: var(--glow); }
.bar span { margin-left: .6rem; }
.body { padding: 1.2rem 1.3rem; }
.hero {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 2.5rem;
  align-items: center;
  min-height: 76vh;
  max-width: 1000px;
  margin: 0 auto;
  padding: 2.5rem 1.2rem 3rem;
}
.lead {
  max-width: 30rem;
  margin: 0 0 1.6rem;
  color: var(--glow);
}
.cta { margin-top: 1.6rem; }
.portrait,
.heartwrap {
  grid-column: 2;
  display: grid;
  align-items: center;
  justify-items: end;
}
.phw {
  position: relative;
  width: min(260px, 60vw);
}
.photo {
  aspect-ratio: 1;
  overflow: hidden;
  border: 3px solid var(--gold);
  border-radius: 50%;
  background: rgba(15, 26, 92, .45);
  box-shadow: 0 0 34px rgba(159, 211, 255, .55), inset 0 0 24px rgba(43, 111, 214, .35);
}
.photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
.tw {
  position: absolute;
  width: var(--s);
  height: auto;
  fill: #ffd75e;
  filter: drop-shadow(0 0 8px #ffd75e);
  animation: twinkle 3s ease-in-out infinite;
  animation-delay: var(--d);
}
@keyframes twinkle {
  0%, 100% { opacity: .45; transform: scale(.8) rotate(0); }
  50%      { opacity: 1;   transform: scale(1.15) rotate(15deg); }
}
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.2rem;
}
.glass {
  position: relative;
  padding: 1rem 1rem 1.3rem;
  background: var(--panel);
  border: 1px solid rgba(159, 211, 255, .4);
  border-radius: 0;
  backdrop-filter: blur(8px);
  box-shadow: 0 0 30px rgba(43, 111, 214, .25);
}
.glass:nth-child(even) {
  border-radius: 0;
}
.glass::before {
  content: "";
  position: absolute;
  inset: 6px;
  border: 1px solid rgba(242, 199, 92, .3);
  border-radius: 0;
  pointer-events: none;
}
.glass:nth-child(even)::before {
  border-radius: 0;
}
.glass:hover {
  border-color: var(--gold);
  box-shadow: 0 0 42px rgba(242, 199, 92, .5);
}
.portal {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: rgba(7, 11, 42, .6);
  border: 2px solid rgba(242, 199, 92, .7);
  border-radius: 0;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .25);
}
.portal img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.portal img.pl {
  position: absolute;
  left: .7rem;
  bottom: .7rem;
  width: 110px;
  height: 110px;
  aspect-ratio: 1 / 1;
  padding: 8px;
  object-fit: contain;
  background: rgba(7, 11, 42, .88);
  border: 2px solid var(--gold);
  border-radius: 0;
  box-shadow: 0 0 14px rgba(242, 199, 92, .35);
}
.gb { padding: 1rem .6rem 0; }
.gb h3 {
  margin: 0 0 .5rem;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--glow);
}
.gb p { margin: 0 0 .8rem; }
.tags {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem;
}
.tags span {
  padding: 0 .55rem;
  border: 1px solid rgba(255, 143, 177, .45);
  border-radius: 4px;
  font-size: .78rem;
  color: var(--rose);
}
.sk-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.4rem;
  align-items: stretch;
}
.sk h3 {
  margin: 0 0 .5rem;
  font-size: 1rem;
  font-weight: 600;
  color: var(--glow);
}
.sk ul {
  margin: 0;
  padding: 0;
  list-style: none;
}
.sk li {
  display: flex;
  align-items: center;
  gap: .6rem;
  padding: .6rem 0;
  border-top: 1px solid rgba(242, 199, 92, .35);
}
.sk-n {
  flex: none;
  width: 1.8rem;
  font-family: var(--serif);
  color: var(--gold);
}
.sk-s {
  flex: 1;
  font-family: var(--serif);
  font-size: .92rem;
  line-height: 1.25;
}
.lvl {
  display: inline-flex;
  flex: none;
  gap: .25rem;
}
.lvl i {
  width: 13px;
  height: 13px;
  background: rgba(242, 199, 92, .25);
  clip-path: polygon(50% 0, 60% 40%, 100% 50%, 60% 60%, 50% 100%, 40% 60%, 0 50%, 40% 40%);
}
.lvl i.on { background: var(--gold); }
.lvl-t {
  color: var(--gold);
  font-size: .85rem;
  font-weight: 600;
}
.tools {
  max-width: 760px;
  margin: 0 auto;
  padding: 0;
  list-style: none;
  border-bottom: 1px solid rgba(242, 199, 92, .35);
}
.tool-row {
  display: flex;
  gap: 1.8rem;
  padding: 1.4rem 0;
  border-top: 1px solid rgba(242, 199, 92, .35);
}
.tool-num {
  flex: none;
  width: 2.6rem;
  font-family: var(--serif);
  color: var(--gold);
}
.tool-row h3 {
  margin: 0;
  font-family: var(--serif);
  font-weight: 500;
  font-size: 1.5rem;
  color: var(--text);
}
.tool-row ul {
  display: flex;
  flex-wrap: wrap;
  margin: .5rem 0 0;
  padding: 0;
  list-style: none;
  color: var(--glow);
  line-height: 1.7;
}
.tool-row li + li::before {
  content: "";
  display: inline-block;
  width: 10px;
  height: 10px;
  margin: 0 .9rem;
  background: var(--gold);
  clip-path: polygon(50% 0, 60% 40%, 100% 50%, 60% 60%, 50% 100%, 40% 60%, 0 50%, 40% 40%);
}
@media (max-width: 600px) {
  .tool-row { gap: 1rem; }
  .tool-row h3 { font-size: 1.2rem; }
}
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 1.4rem;
}
.gallery:not(.open) figure.is-hidden {
  display: none;
}
.gallery.open figure.is-hidden {
  animation-delay: calc(var(--reveal, 0) * 45ms);
}
.gallery figure {
  margin: 0;
  animation: art-in .7s cubic-bezier(.2, .7, .2, 1) backwards;
  animation-delay: calc(var(--i, 0) * 55ms);
}
@keyframes art-in {
  from { opacity: 0; transform: translateY(20px) scale(.985); }
  to   { opacity: 1; transform: none; }
}
.art {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  padding: 8px;
  overflow: hidden;
  background: rgba(10, 18, 70, .55);
  border: 1px solid rgba(242, 199, 92, .32);
  border-radius: 4px;
  box-shadow: 0 14px 34px -22px rgba(0, 0, 0, .95);
  cursor: zoom-in;
  transition: transform .45s cubic-bezier(.2, .7, .2, 1), border-color .3s ease, box-shadow .45s ease;
}
.art::before {
  content: "";
  position: absolute;
  inset: 4px;
  z-index: 2;
  border: 1px solid rgba(242, 199, 92, .2);
  border-radius: 2px;
  pointer-events: none;
  transition: border-color .3s ease;
}
.art img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 2px;
  filter: saturate(.92) brightness(.94);
  transition: transform .7s cubic-bezier(.2, .7, .2, 1), filter .45s ease;
}
.art:hover,
.art:focus-visible {
  transform: translateY(-5px);
  border-color: var(--gold);
  box-shadow:
    0 0 34px rgba(242, 199, 92, .26),
    0 22px 42px -24px rgba(0, 0, 0, .95);
  outline: none;
}
.art:hover::before,
.art:focus-visible::before {
  border-color: rgba(242, 199, 92, .45);
}
.art:hover img,
.art:focus-visible img {
  transform: scale(1.045);
  filter: saturate(1.04) brightness(1);
}
.gal-more {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  max-width: 560px;
  margin: 2.4rem auto 0;
}
.gal-more[hidden] { display: none; }
.gal-more::before,
.gal-more::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(242, 199, 92, .6));
}
.gal-more::after {
  background: linear-gradient(270deg, transparent, rgba(242, 199, 92, .6));
}
.gal-more-btn {
  display: inline-flex;
  align-items: center;
  gap: .7rem;
  padding: .65rem 1.5rem;
  background: rgba(7, 11, 42, .6);
  border: 1px solid var(--gold);
  border-radius: 999px;
  font: inherit;
  font-size: .85rem;
  letter-spacing: .1em;
  color: var(--gold);
  cursor: pointer;
  box-shadow: 0 0 18px rgba(242, 199, 92, .18);
  transition: background .25s ease, color .25s ease, box-shadow .25s ease, transform .25s ease;
}
.gal-more-btn::before {
  content: "✦";
  font-size: .9rem;
}
.gal-more-btn:hover,
.gal-more-btn:focus-visible {
  background: var(--gold);
  color: var(--night);
  box-shadow: 0 0 30px rgba(242, 199, 92, .55);
  transform: translateY(-2px);
  outline: none;
}
.gal-more-count {
  padding: 0 .5rem;
  background: rgba(242, 199, 92, .18);
  border-radius: 999px;
  font-size: .72rem;
  letter-spacing: 0;
}
.gal-more-count:empty { display: none; }
.gal-more-btn:hover .gal-more-count,
.gal-more-btn:focus-visible .gal-more-count {
  background: rgba(7, 11, 42, .18);
}
.gal-more-btn .chev {
  width: .45rem;
  height: .45rem;
  margin-top: -.2rem;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  transition: transform .3s ease;
}
.gal-more-btn[aria-expanded="true"] .chev {
  margin-top: .2rem;
  transform: rotate(225deg);
}
/* --- Visionneuse --- */
#viewer {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: clamp(3.6rem, 7vh, 5rem) clamp(.8rem, 5vw, 4rem) 1.4rem;
  background: none;
  border: 0;
  color: var(--text);
  overflow: hidden;
}
#viewer[open] {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(.4rem, 3vw, 2.2rem);
}
#viewer::backdrop {
  background: rgba(3, 6, 24, .94);
  backdrop-filter: blur(12px);
}
.vwrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .9rem;
  min-width: 0;
  max-width: 100%;
}
#viewer figure {
  position: relative;
  margin: 0;
  padding: 10px;
  background: rgba(10, 18, 70, .6);
  border: 1px solid rgba(242, 199, 92, .5);
  border-radius: 4px;
  box-shadow:
    0 0 60px rgba(43, 111, 214, .35),
    0 34px 90px -44px #000;
}
#viewer figure::before {
  content: "";
  position: absolute;
  inset: 4px;
  border: 1px solid rgba(242, 199, 92, .18);
  border-radius: 2px;
  pointer-events: none;
}
#viewer img {
  display: block;
  max-width: min(74vw, 1000px);
  max-height: 68vh;
  object-fit: contain;
  border-radius: 1px;
}
.vmeta {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .65rem;
  max-width: 100%;
}
#vcount {
  margin: 0;
  font-family: var(--serif);
  font-size: .85rem;
  letter-spacing: .32em;
  color: var(--gold);
}
.vthumbs {
  display: flex;
  gap: .45rem;
  max-width: min(74vw, 1000px);
  padding: .15rem .15rem .45rem;
  overflow-x: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(242, 199, 92, .4) transparent;
}
.vthumbs::-webkit-scrollbar { height: 5px; }
.vthumbs::-webkit-scrollbar-thumb {
  background: rgba(242, 199, 92, .35);
  border-radius: 999px;
}
.vthumb {
  flex: none;
  width: 50px;
  height: 50px;
  padding: 0;
  background-color: rgba(10, 18, 70, .8);
  background-size: cover;
  background-position: center;
  border: 1px solid rgba(159, 211, 255, .22);
  border-radius: 3px;
  opacity: .5;
  cursor: pointer;
  transition: opacity .25s ease, border-color .25s ease, box-shadow .25s ease, transform .25s ease;
}
.vthumb:hover,
.vthumb:focus-visible {
  opacity: 1;
  border-color: var(--glow);
  outline: none;
}
.vthumb.on {
  opacity: 1;
  border-color: var(--gold);
  box-shadow: 0 0 14px rgba(242, 199, 92, .5);
  transform: translateY(-2px);
}
.vb {
  width: 2.7rem;
  height: 2.7rem;
  flex: none;
  background: rgba(7, 11, 42, .78);
  border: 1px solid rgba(242, 199, 92, .55);
  border-radius: 50%;
  font: inherit;
  font-size: 1.3rem;
  line-height: 1;
  color: var(--gold);
  cursor: pointer;
  transition: background .25s ease, color .25s ease, box-shadow .25s ease;
}
.vb:hover,
.vb:focus-visible {
  background: var(--gold);
  color: var(--night);
  box-shadow: 0 0 22px rgba(242, 199, 92, .55);
  outline: none;
}
.vclose {
  position: fixed;
  top: max(1rem, env(safe-area-inset-top));
  right: max(1rem, env(safe-area-inset-right));
  z-index: 2;
}
.timeline {
  max-width: 640px;
  margin-left: .6rem;
  padding-left: 1.6rem;
  border-left: 2px solid rgba(242, 199, 92, .6);
}
.timeline div {
  position: relative;
  margin-bottom: 1.8rem;
}
/* Losange sur la ligne */
.timeline div::before {
  content: "";
  position: absolute;
  top: .5rem;
  left: -2.05rem;
  width: 14px;
  height: 14px;
  background: var(--gold);
  box-shadow: 0 0 14px var(--gold);
  transform: rotate(45deg);
}
.timeline b {
  font-family: var(--serif);
  font-size: 1.05rem;
  letter-spacing: .04em;
  color: #fff;
}
.timeline small {
  display: block;
  color: var(--glow);
}
.contact {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.4rem;
  max-width: 900px;
  margin: 0 auto;
}
.cc {
  display: block;
  width: 260px;
  max-width: 100%;
  padding: 1.6rem 1rem 1.3rem;
  text-align: center;
  text-decoration: none;
  color: var(--text);
}
.cc:focus-visible {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 38px rgba(242, 199, 92, .4);
}
.cc .fl {
  display: block;
  width: 78px;
  margin: 0 auto .5rem;
  animation: float 4.5s ease-in-out infinite;
}
.cc:nth-child(2) .fl { animation-delay: -1.5s; }
.cc:nth-child(3) .fl { animation-delay: -3s; }
@keyframes float {
  50% { transform: translateY(-6px); }
}
.cc .star {
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 0 10px rgba(255, 215, 94, .7));
  transition: .3s;
}
.cc:hover .star,
.cc:focus-visible .star {
  transform: scale(1.18) rotate(10deg);
  filter: drop-shadow(0 0 18px #fff3c4);
}
.cc h3 {
  margin: .2rem 0;
  font-family: var(--serif);
  font-size: 1.2rem;
  color: #fff;
}
.cc small {
  font-size: .8rem;
  word-break: break-all;
  color: var(--glow);
}
nav {
  position: fixed;
  top: 50%;
  left: .8rem;
  z-index: 50;
  transform: translateY(-50%);
}
.nb {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: .2rem;
  padding: .7rem .45rem;
  background: rgba(7, 11, 42, .74);
  border: 1px solid rgba(242, 199, 92, .55);
  border-radius: 30px 8px 30px 8px;
  backdrop-filter: blur(12px);
  box-shadow: 0 0 28px rgba(43, 111, 214, .35);
}
.nb a {
  position: relative;
  display: flex;
  align-items: center;
  gap: .6rem;
  padding: .4rem .5rem;
  border-radius: 999px;
  font-family: var(--serif);
  font-size: .85rem;
  white-space: nowrap;
  text-decoration: none;
  color: var(--glow);
  transition: .25s;
}
.nb a:not(.logo)::before {
  content: "✦";
  width: 1.2rem;
  font-size: 1.1rem;
  text-align: center;
  transition: .25s;
}
.nb a i { display: none; }
.nb a { gap: 0; }
.nb a span {
  display: block;
  max-width: 0;
  padding-left: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-width .35s ease, padding-left .35s ease, opacity .25s ease;
}
.nb:hover a span,
.nb:focus-within a span {
  max-width: 12rem;
  padding-left: .6rem;
  padding-right: .5rem;
  opacity: 1;
}
.nb a:hover,
.nb a:focus-visible,
.nb a.on {
  color: var(--gold);
  outline: none;
}
.nb a.on::before {
  text-shadow: 0 0 10px var(--gold);
  transform: scale(1.25);
}
.nb a.logo {
  align-self: stretch;
  justify-content: center;
  margin: 0 -.45rem .3rem;
  padding: .1rem .45rem .5rem;
  border-bottom: 1px solid rgba(242, 199, 92, .35);
  border-radius: 0;
}
.nb .nh {
  display: block;
  width: 26px;
  height: 26px;
  filter: drop-shadow(0 0 6px var(--glow));
}
.github-heart {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.2rem;
  margin: 2.2rem auto 0;
}
.github-heart a {
  display: block;
  flex: none;
  width: 90px;
  line-height: 0;
  transition: transform .25s ease;
}
.github-heart img {
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 0 8px rgba(255, 143, 177, .8))
          drop-shadow(0 0 20px rgba(255, 143, 177, .5));
}
.github-heart a:hover,
.github-heart a:focus-visible {
  transform: scale(1.1);
}
.github-heart span {
  color: var(--gold);
  font-family: var(--serif);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-shadow: 0 0 14px rgba(242, 199, 92, .5);
}
@media (max-width: 1100px) {
  body { padding-left: 54px; }
  nav  { left: .4rem; }
}
@media (max-width: 760px) {
  .hero {
    grid-template-columns: 1fr;
    min-height: 0;
  }
  .portrait,
  .heartwrap {
    grid-column: 1;
    order: -1;
    justify-items: center;
  }
  .phw { width: 170px; }
  #viewer {
    padding: 3.6rem .5rem 1rem;
    gap: .15rem;
  }
  #viewer img {
    max-width: calc(100vw - 5.4rem);
    max-height: 60vh;
  }
  .vthumbs { max-width: calc(100vw - 1rem); }
  .vb { width: 2.3rem; height: 2.3rem; font-size: 1.1rem; }
  .vthumb { width: 42px; height: 42px; }
}
@media (max-width: 520px) {
  .gallery {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .8rem;
  }
  .art { padding: 5px; }
  .gal-more { gap: .6rem; }
}
@media (max-height: 620px) {
  #viewer img { max-height: 56vh; }
  .vthumbs { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, ::before, ::after {
    animation: none !important;
    transition: none !important;
  }
  html { scroll-behavior: auto; }
  .tw  { opacity: 1; }
}
@media (max-width: 980px) {
  .sk-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 620px) {
  .sk-grid { grid-template-columns: 1fr; }
}