:root{
  --ink:#272727;
  --ink-soft:#30302f;
  --ecru:#fff2cc;
  --blue:#4472c4;
  --aptos:"Aptos", "Segoe UI", Arial, Helvetica, sans-serif;
  --page-pad:clamp(18px, 3vw, 48px);
}

*{ box-sizing:border-box; }
html,body{ margin:0; min-height:100%; }
html{ background:var(--ink); }
body{
  background:var(--ink);
  color:var(--ecru);
  font-family:var(--aptos);
  font-size:15px;
  line-height:1.5;
  -webkit-font-smoothing:antialiased;
}
a{ color:inherit; }
button{ font:inherit; }

.site-shell{
  min-height:100vh;
  display:grid;
  grid-template-rows:auto minmax(0,1fr) auto;
  background:var(--ink);
}

/* Górny pasek */
.topbar{
  min-height:62px;
  padding:15px var(--page-pad) 13px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:28px;
  border-bottom:1px solid var(--blue);
  background:var(--ink);
}
.brand{
  text-decoration:none;
  font-size:clamp(18px, 1.45vw, 23px);
  font-weight:400;
  letter-spacing:.005em;
  white-space:nowrap;
}
.nav{
  display:flex;
  align-items:center;
  gap:clamp(18px, 2.7vw, 40px);
}
.nav a{
  position:relative;
  text-decoration:none;
  font-size:11px;
  letter-spacing:.12em;
  text-transform:uppercase;
  white-space:nowrap;
  opacity:.84;
}
.nav a::after{
  content:"";
  position:absolute;
  left:0;
  right:100%;
  bottom:-7px;
  height:1px;
  background:var(--blue);
  transition:right .22s ease;
}
.nav a:hover,
.nav a.is-current{ opacity:1; }
.nav a:hover::after,
.nav a.is-current::after{ right:0; }

/* Okno z filmem. Na desktopie wypełnia wolną wysokość ekranu. */
.hero-wrap{
  min-height:0;
  padding:10px var(--page-pad);
  display:flex;
  align-items:stretch;
}
.hero-stage{
  position:relative;
  width:100%;
  min-height:0;
  height:100%;
  overflow:hidden;
  background:var(--ink-soft);
  isolation:isolate;
}
.video-stack,
.hero-video,
.video-shade{
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
}
.hero-video{
  object-fit:cover;
  opacity:0;
  transition:opacity .65s ease;
  background:var(--ink-soft);
}
.hero-video.is-active{ opacity:1; }
.video-shade{
  pointer-events:none;
  background:linear-gradient(180deg, rgba(0,0,0,.05) 0%, rgba(0,0,0,.02) 55%, rgba(0,0,0,.18) 100%);
}

/* Wspólna karta treści */
.content-panel{
  position:absolute;
  z-index:5;
  left:clamp(16px, 2.3vw, 36px);
  bottom:clamp(16px, 2.3vw, 36px);
  width:min(650px, calc(100% - 32px));
  max-height:calc(100% - 32px);
  padding:30px 34px;
  overflow:auto;
  overscroll-behavior:contain;
  background:rgba(39,39,39,.97);
  color:var(--ecru);
  box-shadow:0 12px 34px rgba(0,0,0,.24);
  opacity:0;
  transform:translateY(7px);
  transition:opacity .2s ease, transform .2s ease;
  scrollbar-width:thin;
  scrollbar-color:var(--blue) rgba(255,242,204,.12);
}
.content-panel.is-visible{
  opacity:1;
  transform:none;
}
.content-panel[hidden]{ display:none; }

.content-panel h2{
  margin:0 0 22px;
  padding-bottom:11px;
  border-bottom:1px solid var(--blue);
  font-size:24px; /* odpowiednik ok. 18 pt */
  line-height:1.12;
  font-weight:400;
  letter-spacing:0;
}

/* Strona startowa */
.content-panel--home{
  width:min(680px, calc(100% - 32px));
  padding:25px 30px 27px;
}
.home-title{
  margin:0 0 18px;
  font-size:24px;
  line-height:1.15;
  font-weight:400;
}
.home-text{
  margin:0;
  font-size:15px; /* odpowiednik ok. 11 pt */
  line-height:1.52;
  text-align:left;
}
.home-text span{ display:block; }

/* O KANCELARII */
.content-panel--about{
  width:min(820px, calc(100% - 32px));
  padding:30px 52px 26px;
}
.about-cards{ position:relative; }
.about-card{ display:none; }
.about-card.is-active{ display:block; animation:cardIn .2s ease both; }
@keyframes cardIn{
  from{ opacity:0; transform:translateX(6px); }
  to{ opacity:1; transform:none; }
}
.about-card p{
  margin:0 0 12px;
  text-align:justify;
  font-size:15px;
  line-height:1.48;
  hyphens:auto;
}
.bio-flow::after{ content:""; display:block; clear:both; }
.portrait{
  float:left;
  width:190px;
  max-width:33%;
  aspect-ratio:1 / 1;
  object-fit:cover;
  margin:1px 24px 10px 0;
  border:0;
}

.card-arrow{
  position:absolute;
  z-index:9;
  top:50%;
  transform:translateY(-50%);
  width:38px;
  height:58px;
  border:0;
  padding:0;
  background:transparent;
  color:var(--blue);
  font-family:var(--aptos);
  font-size:47px;
  font-weight:300;
  line-height:1;
  cursor:pointer;
  opacity:.8;
}
.card-arrow:hover,
.card-arrow:focus-visible{ opacity:1; outline:none; }
.card-arrow--prev{ left:5px; }
.card-arrow--next{ right:5px; }
.card-count{
  margin-top:12px;
  text-align:right;
  font-size:10px;
  letter-spacing:.1em;
  color:rgba(255,242,204,.58);
}

.experience-list{
  margin:0;
  padding:0;
  columns:2;
  column-gap:34px;
  font-size:13px;
  line-height:1.4;
  text-align:justify;
  hyphens:auto;
}
.experience-list li{
  list-style:none;
  break-inside:avoid;
  position:relative;
  margin:0 0 10px;
  padding-left:15px;
}
.experience-list li::before{
  content:"■";
  position:absolute;
  left:0;
  top:.05em;
  color:var(--ecru);
  font-size:.58em;
}

.education-list{
  margin:0;
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:22px 42px;
}
.education-list div{
  min-width:0;
  padding:0;
}
.education-list dt,
.education-list dd{
  margin:0;
  font-size:15px;
  line-height:1.4;
}
.education-list dt{ font-weight:400; }
.education-list dd{
  margin-top:2px;
  color:rgba(255,242,204,.78);
}

/* PRAKTYKA */
.content-panel--practice{
  width:min(740px, calc(100% - 32px));
}
.practice-card{ display:none; }
.practice-card.is-active{ display:block; animation:cardIn .2s ease both; }
.practice-list{
  list-style:none;
  margin:0;
  padding:0;
}
.practice-list li{
  position:relative;
  padding-left:15px;
  margin:0 0 5px;
}
.practice-list li::before{
  content:"•";
  position:absolute;
  left:1px;
  top:0;
  color:var(--ecru);
}
.practice-link{
  border:0;
  padding:1px 0;
  background:transparent;
  color:var(--ecru);
  cursor:pointer;
  text-align:left;
  font-size:15px;
  line-height:1.45;
}
.practice-link:hover,
.practice-link:focus-visible{
  color:#fff7df;
  text-decoration:underline;
  text-decoration-color:var(--blue);
  text-underline-offset:3px;
  outline:none;
}
.practice-copy p{
  margin:0 0 18px;
  font-size:15px;
  line-height:1.54;
  text-align:justify;
  hyphens:auto;
}
.practice-copy p:last-child{ margin-bottom:0; }
.practice-back{
  display:inline-block;
  margin:0 0 11px;
  padding:0;
  border:0;
  background:transparent;
  color:var(--blue);
  cursor:pointer;
  font-size:12px;
  letter-spacing:.04em;
  text-transform:uppercase;
}
.practice-back:hover,
.practice-back:focus-visible{ color:#6f98df; outline:none; }

/* KONTAKT — celowo mniejsza karta, aby odsłonić film. */
.content-panel--contact{
  width:min(560px, calc(100% - 32px));
  padding:28px 32px 30px;
}
.contact-title{
  margin:0;
  font-size:24px;
  line-height:1.15;
  font-weight:400;
}
.contact-rule{
  height:1px;
  background:var(--blue);
  margin:18px 0 23px;
}
.contact-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:18px 32px;
  align-items:start;
  font-size:15px;
}
.contact-grid address{ font-style:normal; }
.contact-grid a{ text-underline-offset:3px; }
.contact-util{
  text-decoration:underline;
  color:var(--blue);
}
.contact-cta{
  display:block;
  margin-top:27px;
  padding:7px 12px 6px;
  border:1px solid var(--ecru);
  text-align:center;
  text-decoration:none;
  font-size:10px;
  letter-spacing:.12em;
  text-transform:uppercase;
  transition:background .18s ease, color .18s ease, border-color .18s ease;
}
.contact-cta:hover{
  background:var(--ecru);
  color:var(--ink);
  border-color:var(--ecru);
}

/* Dolny pasek */
.footer{
  min-height:38px;
  padding:9px var(--page-pad) 10px;
  border-top:1px solid var(--blue);
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:20px;
  font-size:10px;
  letter-spacing:.09em;
  text-transform:uppercase;
  color:rgba(255,242,204,.86);
  background:var(--ink);
}
.footer-note{ opacity:.7; }

/* Na typowym ekranie desktopowym cała kompozycja mieści się w jednym oknie. */
@media (min-width:901px){
  html,body{ height:100%; overflow:hidden; }
  .site-shell{ height:100dvh; min-height:0; }
}

@media (max-width:900px){
  .site-shell{ min-height:100vh; }
  .topbar{
    align-items:flex-start;
    flex-direction:column;
    gap:12px;
  }
  .nav{ width:100%; justify-content:space-between; gap:12px; }
  .hero-wrap{ min-height:760px; padding:14px var(--page-pad); }
  .hero-stage{ min-height:730px; }
  .content-panel{ max-height:calc(100% - 28px); }
  .experience-list{ columns:1; }
}

@media (max-width:620px){
  :root{ --page-pad:15px; }
  .topbar{ min-height:auto; padding:14px var(--page-pad) 13px; }
  .brand{ font-size:19px; }
  .nav a{ font-size:9px; letter-spacing:.08em; }
  .hero-wrap{ min-height:760px; padding:12px; }
  .hero-stage{ min-height:736px; }
  .content-panel{
    left:10px;
    bottom:10px;
    width:calc(100% - 20px);
    max-height:calc(100% - 20px);
    padding:24px 22px;
  }
  .content-panel--about{ padding:25px 38px 22px; }
  .content-panel h2,
  .home-title,
  .contact-title{ font-size:22px; }
  .home-text span{ display:inline; }
  .home-text span::after{ content:" "; }
  .portrait{
    float:none;
    display:block;
    width:145px;
    max-width:100%;
    margin:0 0 15px;
  }
  .about-card p,
  .practice-copy p,
  .practice-link,
  .contact-grid{ font-size:14px; }
  .experience-list{ font-size:12.5px; }
  .education-list,
  .contact-grid{ grid-template-columns:1fr; }
  .card-arrow{ width:30px; font-size:41px; }
  .card-arrow--prev{ left:1px; }
  .card-arrow--next{ right:1px; }
  .footer{ flex-direction:column; align-items:flex-start; gap:2px; }
}

@media (prefers-reduced-motion:reduce){
  *,*::before,*::after{
    scroll-behavior:auto !important;
    transition:none !important;
    animation:none !important;
  }
  .hero-video:not(.is-active){ display:none; }
}
