:root{
  --bg:#ebe5de; --panel:#f5f1ec; --text:#1e1916; --muted:#6e655d;
  --line:#ddd4ca; --curve:#cfc4b8; --accent:#5c2a2f; --btn:#4a2025; --on-btn:#fff; --dot:#c9a387;
  --shadow:0 1px 2px rgba(60,40,30,.05), 0 12px 32px rgba(60,40,30,.06);
}
@media (prefers-color-scheme:dark){
  :root:not([data-theme="light"]){
    --bg:#141110; --panel:#1d1917; --text:#efe9e3; --muted:#a39a92;
    --line:#332c28; --curve:#453b35; --accent:#d4b8a8; --btn:#6b2c33; --on-btn:#fff; --dot:#a8705e;
    --shadow:none;
  }
}
:root[data-theme="dark"]{
  --bg:#141110; --panel:#1d1917; --text:#efe9e3; --muted:#a39a92;
    --line:#332c28; --curve:#453b35; --accent:#d4b8a8; --btn:#6b2c33; --on-btn:#fff; --dot:#a8705e;
    --shadow:none;
}

*{box-sizing:border-box}
html{scroll-behavior:smooth; -webkit-text-size-adjust:100%}
body{margin:0; background:var(--bg); color:var(--text); font:400 16px/1.6 Manrope,system-ui,sans-serif}
a{color:inherit; text-decoration:none}
img{display:block}

/* ---------- nav ---------- */
.nav{
  position:sticky; top:0; z-index:10;
  display:flex; align-items:center; justify-content:center;
  padding:14px 20px; background:color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter:blur(10px); -webkit-backdrop-filter:blur(10px);
}
.nav ul{display:flex; gap:28px; list-style:none; margin:0; padding:0; font-size:14px}
.nav ul a{color:var(--muted); transition:color .15s}
.nav ul a:hover{color:var(--text)}
.icon-btn{
  position:absolute; right:20px; width:38px; height:38px; border-radius:50%;
  display:grid; place-items:center; border:0; background:none; color:var(--text); cursor:pointer;
}
.icon-btn:hover{background:var(--panel)}
.icon-btn svg{width:20px; height:20px}
.theme .moon{display:none}
:root[data-theme="dark"] .theme .sun{display:none}
:root[data-theme="dark"] .theme .moon{display:block}
@media (prefers-color-scheme:dark){
  :root:not([data-theme="light"]) .theme .sun{display:none}
  :root:not([data-theme="light"]) .theme .moon{display:block}
}
.menu{display:none; left:20px; right:auto}
.home{position:absolute; left:20px; width:44px; height:44px; color:var(--accent); display:grid; place-items:center; border-radius:50%; transition:background .15s}
.home:hover{background:var(--panel)}
.home svg{width:38px; height:38px}
.home-dot{fill:var(--dot)}
.lang{position:absolute; right:66px; font-size:13px}
.lang summary{
  list-style:none; cursor:pointer; display:flex; align-items:center; gap:6px;
  padding:7px 10px; border-radius:10px; color:var(--text); font-weight:600; user-select:none;
}
.lang summary::-webkit-details-marker{display:none}
.lang summary::after{content:""; width:6px; height:6px; border:solid currentColor; border-width:0 1.5px 1.5px 0; transform:translateY(-2px) rotate(45deg); transition:transform .15s}
.lang[open] summary::after{transform:translateY(1px) rotate(-135deg)}
.lang summary:hover{background:var(--panel)}
.lang-menu{
  position:absolute; right:0; top:calc(100% + 6px); min-width:140px; z-index:20;
  display:grid; padding:6px; background:var(--panel); border:1px solid var(--line);
  border-radius:14px; box-shadow:0 12px 32px rgba(0,0,0,.12);
}
.lang-menu a{padding:9px 12px; border-radius:9px; font-size:14px; color:var(--text)}
.lang-menu a:hover{background:var(--bg)}
.lang-menu a[aria-current]{color:var(--accent); font-weight:600}

/* ---------- panels ---------- */
main{max-width:1440px; margin:0 auto; padding:8px 20px 40px; display:grid; gap:20px}
.panel{
  position:relative; overflow:hidden; scroll-margin-top:72px;
  background:var(--panel); border-radius:28px; box-shadow:var(--shadow);
  padding:64px 56px;
}
.split{display:grid; grid-template-columns:1fr 1.15fr; gap:48px; align-items:center; position:relative; z-index:1}
.curve{position:absolute; inset:0; width:100%; height:100%; pointer-events:none; z-index:0}
.curve path{fill:none; stroke:var(--curve); stroke-width:1.2}

.num{display:flex; align-items:center; gap:14px; color:var(--muted); font-size:14px; margin:0 0 18px}
.num::after{content:""; width:40px; height:1px; background:var(--line)}
h1,h2,h3{font-family:"Cormorant Garamond",Georgia,serif; font-weight:500; margin:0; letter-spacing:-.01em}
h1{font-size:clamp(48px,6.4vw,84px); line-height:.98}
h2{font-size:clamp(40px,4.6vw,58px); line-height:1.05; margin-bottom:24px}
h3{font-size:26px; line-height:1.15}
.role{color:var(--text); font-size:20px; margin:20px 0 28px}
.employer{
  display:grid; gap:2px; margin:0 0 20px; padding:16px 20px;
  border:1px solid var(--line); border-left:3px solid var(--accent); border-radius:14px;
  background:var(--bg); transition:border-color .15s;
}
.employer:hover{border-color:var(--accent)}
.employer-label{font-size:12px; letter-spacing:.08em; text-transform:uppercase; color:var(--muted)}
.employer-name{font:500 30px/1.15 "Cormorant Garamond",Georgia,serif}
.employer-role{font-size:15px; color:var(--accent)}
.text{color:var(--text); max-width:38em; margin:0 0 16px}
.nw{white-space:nowrap}
.text.big{font-size:18px}
.muted{color:var(--muted)}
.small{font-size:14px; margin-top:28px; color:var(--accent)}

.btn{
  display:inline-flex; align-items:center; gap:8px; margin-top:16px;
  background:var(--btn); color:var(--on-btn); padding:11px 20px; border-radius:99px;
  font-size:14px; font-weight:500; transition:filter .15s;
}
.btn:hover{filter:brightness(1.15)}

/* ---------- photos (placeholder gradients until img/*.jpg exist) ---------- */
.ph{position:relative; overflow:hidden; border-radius:22px}
.ph img{position:absolute; inset:0; width:100%; height:100%; object-fit:cover; z-index:1}
.ph::after{
  content:attr(data-label); position:absolute; left:16px; bottom:12px;
  font-size:12px; color:rgba(255,255,255,.75); letter-spacing:.04em;
}
.arch{border-top-left-radius:58% 46%}
/* theme-specific photos */
.dark-only{display:none}
:root[data-theme="dark"] .light-only{display:none}
:root[data-theme="dark"] .dark-only{display:block}
@media (prefers-color-scheme:dark){
  :root:not([data-theme="light"]) .light-only{display:none}
  :root:not([data-theme="light"]) .dark-only{display:block}
}
.g-sunset{background:linear-gradient(170deg,#d9c6c4 0%,#e7b9a6 45%,#8c7a78 100%)}
.g-room{background:linear-gradient(160deg,#efe9e3,#c9bfb5)}
.g-warm{background:radial-gradient(circle at 40% 25%,#e3c3a2 0%,#9b7a5c 45%,#3a2a22 100%)}
.g-mount{background:linear-gradient(180deg,#c8cdd3 0%,#9aa3a8 45%,#5b5a4c 100%)}
.g-shadow{background:linear-gradient(120deg,#e6d6c8 0%,#c4a993 60%,#8f7562 100%)}
.g-silk{background:radial-gradient(ellipse at 30% 60%,#c3304a 0%,#7d1d33 50%,#3d0d18 100%)}
.g-violet{background:radial-gradient(circle at 60% 55%,#9b8ad6 0%,#c8bfe9 40%,#e9e6f6 100%)}
.g-app{background:linear-gradient(160deg,#eef0f3,#cfd5dd)}

/* ---------- hero ---------- */
.hero{padding-bottom:0}
.hero .split{align-items:end}
.hero .copy{align-self:center}
.hero .copy{padding:40px 0 64px}
/* portrait frame keeps the photo's own shape on every screen, so nothing gets cut at the neck */
/* portrait frame keeps the photo's own shape on every screen, so nothing gets cut at the neck */
.hero .ph{aspect-ratio:4 / 5; width:min(100%, 500px); justify-self:end; border-bottom-left-radius:0; border-bottom-right-radius:0}
/* dark portrait: hair touches the photo's top edge, so push it down and fade into a matching backdrop */
.hero .ph:has(.hero-dark){background:#130f0d}
.ph img.hero-dark{
  top:5%; height:95%; object-position:50% 0;
  -webkit-mask-image:linear-gradient(to bottom,transparent 0,#000 3%);
  mask-image:linear-gradient(to bottom,transparent 0,#000 3%);
}
.skills{
  position:relative; z-index:1; display:grid; grid-template-columns:repeat(5,1fr);
  border-top:1px solid var(--line); margin:0 -56px; padding:22px 24px; background:var(--panel);
}
.skills span{text-align:center; font-size:14px; padding:4px 12px; border-left:1px solid var(--line)}
.skills span:first-child{border-left:0}

/* ---------- work ---------- */
.work .split{grid-template-columns:1fr 1fr}
.work .employer{padding:28px 32px; margin:0}
.work .employer-name{font-size:44px}
.cards{display:grid; grid-template-columns:repeat(3,1fr); gap:14px}
.card{
  display:flex; flex-direction:column; background:var(--bg); border:1px solid var(--line);
  border-radius:18px; padding:10px 10px 16px; transition:transform .2s;
}
a.card:hover{transform:translateY(-3px)}
.card .ph{height:120px; border-radius:12px; margin-bottom:16px}
.card h3{font-size:24px; padding:0 8px}
.card p{font-size:13px; color:var(--muted); margin:6px 0 0; padding:0 8px; flex:1}
.card .arrow{align-self:flex-end; color:var(--accent); font-size:20px; padding:8px 8px 0}

/* ---------- dance / travel / contact ---------- */
/* keep frames from turning wide and short on big screens, which crops heads */
.tall{min-height:420px; aspect-ratio:4 / 3}
/* vertical photos get a vertical frame */
.portrait{aspect-ratio:4 / 5; min-height:0; width:min(100%, 460px); justify-self:end}
.dance .media{position:relative}
.dance .media::before{
  content:""; position:absolute; left:-28px; bottom:0; width:60px; height:46%;
  background:var(--btn); border-radius:18px 0 0 0;
}
.contacts{list-style:none; padding:0; margin:28px 0 0; display:grid; gap:18px}
.contacts a{display:flex; align-items:center; gap:14px; white-space:nowrap}
#contact .split{grid-template-columns:1fr 1fr; gap:32px}
#contact .contacts a{font-size:15px}
.contacts a:hover{color:var(--accent)}
.contacts svg{width:20px; height:20px; flex:none}

/* ---------- work page ---------- */
.cv{display:grid; gap:0}
.cv-item{display:grid; grid-template-columns:200px 1fr; gap:32px; padding:26px 0; border-top:1px solid var(--line)}
.cv-item:first-child{border-top:0; padding-top:0}
.cv-when{margin:0; font-weight:600}
.cv-where{margin:2px 0 0; color:var(--muted); font-size:14px}
.cv-item h3{font-size:28px}
.cv-org{margin:4px 0 0; color:var(--accent); font-weight:500}
.cv-note{margin:4px 0 0; color:var(--muted); font-size:15px}
.cv-list{margin:12px 0 0; padding-left:18px; display:grid; gap:6px; max-width:42em}
.cv-logo{width:56px; height:56px; margin-top:12px; border-radius:14px}
.cv-link{margin-top:6px}
.cv-product{margin-top:18px}
.cv-product h4{font:500 22px/1.2 "Cormorant Garamond",Georgia,serif; margin:0}
.cv-product + .cv-product{padding-top:18px; border-top:1px dashed var(--line)}
.skill-groups{margin:0; display:grid; gap:14px}
.skill-groups div{display:grid; grid-template-columns:200px 1fr; gap:32px}
.skill-groups dt{font-weight:600}
.skill-groups dd{margin:0; color:var(--text)}
.cv-result{margin:12px 0 0; max-width:42em; color:var(--muted); font-style:italic}
.tags{display:flex; flex-wrap:wrap; gap:10px}
.tag{border:1px solid var(--line); background:var(--bg); border-radius:99px; padding:8px 16px; font-size:15px}
.page .cards{margin-bottom:8px}
.back{display:inline-flex; gap:8px; color:var(--muted); font-size:14px; margin-bottom:28px}
.back:hover{color:var(--accent)}
.page-head{display:grid; grid-template-columns:1fr 1fr; gap:48px; align-items:end; margin-bottom:56px}
.page-head .employer{margin:0}
.page-head:has(.head-photo){align-items:center}
.head-photo{width:auto; max-width:100%; max-height:560px; height:auto; border-radius:22px; display:block; justify-self:end}
.page-head > :only-child{grid-column:1 / -1}
.page-head > :only-child .text{max-width:46em}
.page .cards{gap:20px}
.page .card .ph{height:200px}
.page .card h3{font-size:30px}
.page .card p{font-size:15px}
@media (max-width:760px){
  .page-head{grid-template-columns:1fr; gap:24px; margin-bottom:36px}
  .cv-item{grid-template-columns:1fr; gap:8px}
  .skill-groups div{grid-template-columns:1fr; gap:2px}
  .head-photo{justify-self:start}
  .page .card .ph{height:170px}
}

.entries{display:grid; gap:48px}
.entry{display:grid; grid-template-columns:3fr 2fr; gap:48px; align-items:center}
/* photo is moved to the right on even rows, so the wide column moves with it */
.entry:nth-child(even){grid-template-columns:2fr 3fr}
.entry:nth-child(even) .entry-photo{order:2}
/* show photos whole, no cropping */
.entry-photo{background:none; overflow:visible; border-radius:0; display:flex}
.entry:nth-child(even) .entry-photo{justify-content:flex-end}
.entry-photo img{position:static; width:auto; height:auto; max-width:100%; max-height:680px; border-radius:22px}
/* result without a photo yet: keep a calm placeholder in the photo's place */
.entry-photo:not(:has(img)){aspect-ratio:4 / 3; width:100%; border-radius:22px; background:linear-gradient(160deg,var(--line),var(--bg))}
.results{list-style:none; padding:0; margin:6px 0 0; display:grid; gap:10px}
.results li{display:flex; gap:12px; align-items:baseline; color:var(--muted)}
.results .rank{flex:none; min-width:84px; color:var(--accent); font-weight:600}
h2.sub{font-size:clamp(30px,3.4vw,42px); margin:72px 0 32px; padding-top:40px; border-top:1px solid var(--line)}
.entry-text .place{font-size:12px; letter-spacing:.08em; text-transform:uppercase; color:var(--accent); margin:0 0 8px}
.entry-text h3{font-size:34px; margin-bottom:12px}
.entry-text p{margin:0 0 14px; max-width:32em}
.link{display:inline-flex; gap:8px; color:var(--accent); font-weight:500}
.link:hover{text-decoration:underline; text-underline-offset:4px}
@media (max-width:1000px){
  .entry, .entry:nth-child(even){grid-template-columns:1fr; gap:18px}
  .entry:nth-child(even) .entry-photo{order:0; justify-content:flex-start}
  .entry-photo img{max-height:85vh}
  .entry-text:not(:has(h3,p,a)){display:none}
}

footer{text-align:center; color:var(--muted); font-size:13px; padding:8px 0 32px}

/* ---------- responsive ---------- */
@media (max-width:900px){
  .work .split{grid-template-columns:1fr}
  .work .employer-name{font-size:34px}
}
@media (max-width:760px){
  .nav{justify-content:flex-end; padding:10px 16px}
  .nav ul{
    display:none; position:absolute; top:58px; left:16px; right:16px;
    flex-direction:column; gap:0; background:var(--panel); border-radius:18px;
    padding:8px; box-shadow:0 12px 32px rgba(0,0,0,.12);
  }
  .nav.open ul{display:flex}
  .nav ul a{display:block; padding:12px 14px; font-size:16px; color:var(--text)}
  .icon-btn{position:static}
  .menu{display:grid}
  .lang{position:static; margin-right:6px}
  .home{position:static; order:-2; width:40px; height:40px}
  .home svg{width:34px; height:34px}
  .nav .theme{order:-1; margin-right:auto}
  main{padding:4px 12px 32px; gap:12px}
  .panel{padding:40px 22px; border-radius:24px}
  .split{grid-template-columns:1fr; gap:32px}
  #contact .split{grid-template-columns:1fr}
  .contacts a{white-space:normal}
  .hero{padding-top:20px}
  .hero .split{display:flex; flex-direction:column-reverse}
  .hero .copy{padding:0 0 40px}
  .hero .ph{width:100%; border-radius:22px; border-top-left-radius:58% 46%}
  .skills{grid-template-columns:repeat(2,1fr); margin:0 -22px; gap:10px 0}
  .skills span{border-left:0}
  .cards{grid-template-columns:1fr}
  .tall{min-height:0}
  .ph{max-width:100%}
  .portrait{width:100%; justify-self:stretch}
  .dance .media::before{display:none}
}
