/* Priority layout layer. Shared palette and existing client content are retained. */
*, *::before, *::after { box-sizing:border-box; }
img { max-width:100%; }
.it-butik { display:none; }
.blog-page, .archive-project, .archive-service, .contacts-page, section.single-post { padding-top:176px; }
body.single-post { padding-top:0; }
:where(section[id],h2[id],h3[id]) { scroll-margin-top:140px; }
.sec_zag { margin-top:0; margin-bottom:36px; }
:is(.main_zag,.sec_zag,.proj_zag,.port_name,.post_name,.zam-service-copy h3,.zam-rich-copy h2) { text-wrap:balance; }
.usl_cena { font-style:normal; font-size:clamp(24px,2.2vw,32px); font-weight:400; line-height:1.4; }
.main_header, .usl_fon, .proj_fon, .about_fon { min-height:0; padding-top:176px; padding-bottom:64px; }
:is(.main_header,.usl_fon,.proj_fon,.about_fon) .main_zag { margin:0 0 24px; }
@media(min-width:801px) {
  .main_header { min-height:100vh; padding-top:70px; padding-bottom:100px; }
  .main_header .main_zag { margin:120px 0 10px; font-size:clamp(36px,4.3vw,74px); text-wrap:wrap; }
  .main_header .main_row { margin:70px 0; }
  .main_header .main_col { margin:20px 0; }
}
.usl_fon .usl_icos { margin:32px 0; }
.usl_fon .usl_ico { margin:14px 0; }
.usl_fon .usl_ico img { width:34px; margin-right:16px; }
.usl_fon .usl_ico p { font-size:17px; line-height:1.55; }
.about_cif_row { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:24px; width:56%; margin:32px 0; }
.about_cif_col { width:auto; margin:0; min-width:0; }
.about_fon .proj_podzag, .proj_fon .proj_podzag { margin-top:0; margin-bottom:28px; }
.sidebar .zam-services-grid { grid-template-columns:1fr; gap:20px; }
.sidebar .sec_zag { font-size:30px; line-height:1.25; margin:0 0 24px; }
.sidebar .zam-service-photo { aspect-ratio:16/9; }
.sidebar .zam-service-copy { padding:20px; }
.sidebar .zam-service-copy h3 { font-size:22px; }
.post_content p, .post_content li { line-height:1.7; }
.post_content h2 { font-size:28px; font-weight:500; line-height:1.3; margin:36px 0 18px; }
.post_content h3 { font-size:23px; font-weight:500; line-height:1.35; padding-inline:50px; margin:28px 0 16px; }
.post_content > img:first-child { display:block; width:100%; max-height:480px; object-fit:cover; }
.post_row { align-items:flex-start; gap:32px; }
.proj_zag, .port_name { font-size:28px; line-height:1.3; margin:0 0 18px; }
.archive-project .proj_opis { font-size:17px; font-weight:400; line-height:1.65; margin-bottom:24px; }
.zam-mobile-hero { display:none; }
.zam-services-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:28px; }
.zam-service-card { display:flex; flex-direction:column; min-width:0; overflow:hidden; border:1px solid var(--zam-gold-dark); border-radius:var(--zam-radius-card); background:var(--zam-surface-gradient); }
.zam-service-photo { display:block; aspect-ratio:4/3; overflow:hidden; }
.zam-service-photo img { display:block; width:100%; height:100%; object-fit:cover; transition:transform .6s cubic-bezier(.2,.7,.2,1); }
.zam-service-photo:hover img { transform:scale(1.025); }
.zam-service-copy { display:flex; flex-direction:column; flex:1; padding:26px; }
.zam-service-copy h3 { margin:0 0 16px; font-size:clamp(21px,2vw,27px); line-height:1.3; }
.zam-service-copy h3 a { color:var(--zam-gold); }
.zam-service-copy p { font-size:16px; line-height:1.65; margin:0 0 24px; }
.zam-service-copy .usl_butt { position:static; display:inline-block; align-self:flex-start; margin-top:auto; }
/* Give both nested carousels a bounded photo height, so one portrait cannot inflate all slides. */
#port_slider { padding:36px; }
#port_slider .port_block { min-height:0; height:auto; gap:32px; align-items:center; }
.port_gall { min-width:0; }
.port_gall .item { aspect-ratio:4/3; }
.port_gall .item img { width:100%; height:100%; object-fit:cover; display:block; }
#port_slider .port_info { min-width:0; }
#port_slider .port_butts { flex-wrap:wrap; gap:18px 24px; padding:4px 0; }
#port_slider .port_butts .butt_big { flex:none; max-width:100%; padding:14px 20px; height:auto; }
#port_slider .port_butts .butt_big p { white-space:normal; line-height:1.45; }
#port_slider .port_butts .butt_small { margin:0; }
#port_slider .port_block { padding:4px 2px 12px; }
#port_slider > .owl-wrapper-outer { transition:height .38s ease; }
#port_slider > .owl-controls { position:static; margin-top:28px; }
#port_slider > .owl-controls .owl-buttons { display:flex; justify-content:space-between; gap:20px; }
#port_slider > .owl-controls .owl-buttons > div { position:static; width:auto; height:auto; padding:12px 20px; }
.archive-project .proj_block { display:grid; grid-template-columns:minmax(0,42fr) minmax(0,58fr); align-items:center; gap:32px; margin:0 0 32px; padding:28px; min-height:0; }
.archive-project .proj_block > img { position:static; width:100%; height:auto; aspect-ratio:4/3; object-fit:cover; margin:0; }
.archive-project .proj_info { width:auto; min-width:0; margin:0; padding:0; }
.archive-project .proj_row { gap:18px; flex-wrap:wrap; }
.archive-project .proj_zag { line-height:1.35; }
/* Equal-height blog cards, readable gaps and buttons that stay inside the card. */
.blog_row { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:28px; }
.blog_row .blog_post { width:auto; max-width:none; margin:0; display:flex; flex-direction:column; overflow:hidden; }
.blog_post .post_img { flex:none; height:auto; aspect-ratio:16/10; }
.blog_post .post_img img { position:static; transform:none; width:100%; height:100%; object-fit:cover; }
.blog_post .img_light { display:none; }
.blog_post .post_text { position:static; flex:1; margin:0; padding:26px 24px 16px; text-align:left; }
.blog_post .post_name { display:block; margin:0 0 18px; font-size:24px; line-height:1.3; }
.blog_post .post_opis, .blog_post .post_text p { font-size:17px; line-height:1.65; }
.blog_post .post_butt { align-self:flex-start; margin:8px 24px 26px; }
.zam-project-intro { max-width:72ch; margin-bottom:36px; font-size:18px; line-height:1.7; }
.zam-project-gallery { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:24px; padding:0; margin:36px 0 64px; }
.zam-gallery-photo { position:relative; display:block; min-width:0; overflow:hidden; border-radius:var(--zam-radius-image); }
.zam-gallery-photo:first-child { grid-column:1/-1; }
.zam-gallery-photo img { display:block; width:100%; height:auto; }
.zam-gallery-photo:first-child img { aspect-ratio:16/10; max-height:780px; object-fit:cover; }
.zam-gallery-photo:not(:first-child) img { aspect-ratio:4/3; object-fit:cover; }
.zam-gallery-photo span { position:absolute; right:16px; bottom:16px; padding:8px 14px; color:var(--zam-hero); background:var(--zam-gold); border-radius:4px; font-size:14px; }
.zam-project-facts { padding:36px; background:var(--zam-surface-gradient); border:1px solid var(--zam-gold-dark); border-radius:var(--zam-radius-card); }
.zam-project-facts .proj_chars_vn { width:100%; padding:0; }
.zam-project-facts .proj_chars { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:28px; }
.zam-project-facts .char_col_vn { width:auto; margin:0; padding-left:28px; }
.zam-project-video { max-width:900px; margin:48px auto; }
.zam-project-video .proj_vid { width:100%; margin:0; padding:0; }
.zam-project-video .proj_vid > img { width:100%; height:auto; aspect-ratio:16/9; object-fit:cover; }
.zam-content-rows { display:grid; gap:80px; }
.zam-content-row { display:grid; grid-template-columns:minmax(0,5fr) minmax(0,6fr); align-items:center; gap:36px 48px; padding-top:44px; border-top:1px solid rgba(var(--zam-gold-rgb),.24); }
.zam-content-row:has(> .zam-rich-copy:first-child) { grid-template-columns:1fr; }
.zam-content-photo { margin:0; }
.zam-content-photo img { display:block; width:100%; height:auto; aspect-ratio:4/3; object-fit:cover; border-radius:var(--zam-radius-image); }
.zam-content-intro { max-width:68ch; }
.zam-content-sections { grid-column:1/-1; display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:28px; align-items:start; }
.zam-copy-section { min-width:0; padding:28px 30px; margin:0; border:1px solid rgba(var(--zam-gold-rgb),.2); border-radius:8px; background:rgba(var(--zam-hero-rgb),.18); }
.zam-copy-section:last-child:nth-child(odd) { grid-column:1/-1; }
.zam-copy-section > h3 { font-size:24px; line-height:1.35; font-weight:500; margin:0 0 20px; text-wrap:balance; }
.zam-copy-section .zam-rich-copy > :last-child, .zam-content-intro > :last-child { margin-bottom:0; }
.zam-content-collapsible { display:block; }
.zam-copy-section .zam-rich-copy { font-size:17px; line-height:1.7; }
.zam-copy-section .zam-rich-copy ol { grid-template-columns:repeat(auto-fit,minmax(min(100%,280px),1fr)); }
.zam-rich-copy { min-width:0; font-size:18px; line-height:1.75; }
.zam-rich-copy > h2 { font-size:clamp(26px,2.7vw,38px); line-height:1.25; margin:0 0 24px; }
.zam-rich-copy h3 { font-size:24px; line-height:1.35; margin:30px 0 18px; }
.zam-rich-copy p { margin:0 0 20px; }
.zam-rich-copy li { margin-bottom:12px; }
.zam-rich-copy ul { padding-left:24px; }
.zam-rich-copy ol { counter-reset:work; list-style:none; padding:0; display:grid; gap:14px; }
.zam-rich-copy ol > li { position:relative; counter-increment:work; padding:20px 20px 20px 64px; margin:0; background:var(--zam-surface-gradient); border:1px solid var(--zam-gold-dark); border-radius:var(--zam-radius-control); }
.zam-rich-copy ol > li::before { content:counter(work,decimal-leading-zero); position:absolute; left:18px; top:18px; font-size:24px; color:var(--zam-gold); }
.zam-eyebrow { color:var(--zam-gold); font-size:15px; letter-spacing:.08em; margin-bottom:14px; }
.zam-accordion { border-top:1px solid var(--zam-gold-dark); }
.zam-accordion:last-child { border-bottom:1px solid var(--zam-gold-dark); }
.zam-accordion summary { cursor:pointer; padding:22px 32px 22px 0; position:relative; font-size:20px; line-height:1.45; font-weight:500; list-style:none; }
.zam-accordion summary::-webkit-details-marker { display:none; }
.zam-accordion summary::after { content:'+'; position:absolute; right:4px; color:var(--zam-gold); }
.zam-accordion[open] summary::after { content:'−'; }
.zam-accordion > div { padding-bottom:20px; }
.zam-legal { max-width:900px; margin:auto; padding:150px 24px 56px; font-size:17px; line-height:1.75; overflow-wrap:anywhere; }
.zam-legal h1 { font-size:clamp(30px,4vw,48px); line-height:1.2; margin:32px 0; }
.zam-legal h2 { font-size:26px; line-height:1.35; margin:36px 0 18px; }
.zam-legal ul { padding-left:24px; }
.zam-legal a, .zam-legal-links a { color:var(--zam-gold); text-decoration:underline; }
.zam-legal-links { display:flex; flex-wrap:wrap; justify-content:center; gap:12px 28px; padding:24px; font-size:14px; }
.zam-legal-links button { background:none; border:0; padding:0; color:var(--zam-gold); text-decoration:underline; cursor:pointer; }
.zam-no-map .contacts .wrapper { max-width:960px; }
.zam-no-map .contacts .conts_block { width:100%; }
.zam-no-map .contacts .map { display:none; }
.zam-policy-note { width:100%; font-size:14px; line-height:1.5; margin:14px 0 0; }
.zam-policy-note a { color:var(--zam-gold); text-decoration:underline; }
.zam-cookie-notice { position:fixed; z-index:10001; left:20px; right:20px; bottom:20px; max-width:860px; margin:auto; display:flex; align-items:center; gap:24px; padding:20px 24px; border:1px solid var(--zam-gold-dark); border-radius:var(--zam-radius-card); background:var(--zam-hero); color:var(--zam-text); box-shadow:0 8px 40px rgba(0,0,0,.35); }
.zam-cookie-notice[hidden] { display:none; }
.zam-cookie-notice p { margin:0; font-size:14px; line-height:1.5; }
.zam-cookie-notice a { color:var(--zam-gold); text-decoration:underline; }
.zam-cookie-notice button { flex:none; padding:10px 18px; border:0; border-radius:4px; background:var(--zam-gold); color:var(--zam-hero); cursor:pointer; }
.zam-lightbox { position:fixed; inset:0; width:96vw; max-width:1600px; height:94vh; max-height:94vh; padding:48px 56px 24px; border:1px solid var(--zam-gold-dark); color:var(--zam-text); background:var(--zam-hero); }
.zam-lightbox::backdrop { background:rgba(0,0,0,.85); }
body:has(.zam-lightbox[open]) { overflow:hidden; }
body.zam-popup-active { overflow:hidden; }
.popup[aria-hidden="true"] { display:none; }
.popup.zam-popup-open { display:block; opacity:1; }
.popup .close_wind { display:grid; place-items:center; width:44px; height:44px; border:1px solid var(--zam-gold); border-radius:50%; background:var(--zam-hero); }
.popup .close_wind img { width:22px; height:22px; }
.zam-lightbox[open] { display:flex; align-items:center; justify-content:center; }
.zam-lightbox figure { margin:0; width:100%; height:100%; display:flex; flex-direction:column; align-items:center; justify-content:center; }
.zam-lightbox img { width:100%; min-height:0; flex:1; object-fit:contain; }
.zam-lightbox figcaption { flex:none; padding-top:12px; }
.zam-lightbox button { position:absolute; border:0; background:var(--zam-gold); color:var(--zam-hero); width:44px; height:44px; border-radius:50%; cursor:pointer; font-size:24px; }
.zam-lightbox-close { right:12px; top:10px; }
.zam-lightbox-prev { left:8px; top:50%; }
.zam-lightbox-next { right:8px; top:50%; }
:is(.zam-accordion summary,.zam-gallery-photo,.zam-service-card a,.zam-lightbox button):focus-visible { outline:2px solid var(--zam-gold); outline-offset:5px; }
@media(max-width:1000px) {
  .zam-services-grid, .blog_row { grid-template-columns:repeat(2,minmax(0,1fr)); }
  #port_slider .port_block { flex-direction:column; }
  #port_slider .port_gall, #port_slider .port_info { width:100%; max-width:none; }
  .zam-content-row { gap:28px; }
  .zam-project-facts .proj_chars { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media(max-width:800px) {
  .main_header, .usl_fon, .proj_fon, .about_fon { padding-top:110px; padding-bottom:48px; }
  .sec_zag { margin-bottom:28px; }
  .proj_zag, .port_name { font-size:24px; }
  .post_row { gap:36px; }
  .post_content h2 { font-size:25px; }
  .post_content h3 { font-size:21px; padding-inline:25px; }
  :where(section[id],h2[id],h3[id]) { scroll-margin-top:90px; }
  .blog-page, .archive-project, .archive-service, .contacts-page, section.single-post { padding-top:110px; }
  .zam-legal { padding-top:100px; }
  .about_cif_row, .cif_row { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; width:100%; }
  .about_cif_col, .cif_col { min-width:0; width:auto; }
  .about_cif, .cif { font-size:clamp(28px,8.8vw,44px); white-space:nowrap; }
  .about_cif span, .cif span { font-size:16px; }
  .about_cif_text, .cif_text { font-size:12px; line-height:1.5; overflow-wrap:anywhere; }
  .main_header { padding-top:100px; padding-bottom:40px; background-image:none; }
  .main_header .main_zag { font-size:clamp(32px,7.8vw,44px); margin:0 0 24px; max-width:none; }
  .zam-mobile-hero { display:block; width:100%; margin:0 0 24px; }
  .zam-mobile-hero img { display:block; width:100%; height:auto; aspect-ratio:4/3; object-fit:cover; border-radius:var(--zam-radius-image); }
  .main_header .main_row { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:20px 16px; margin:0 0 24px; padding:22px 12px; width:100%; }
  .main_header .main_col { padding:0; margin:0; width:auto; }
  .main_header .line_v, .main_header .line_h { display:none; }
  .main_header .main_col img { max-height:44px; margin-bottom:12px; }
  .main_header .main_col p { font-size:14px; line-height:1.45; }
  .main_header .butts_line { margin-top:24px; }
  .archive-project .proj_block { grid-template-columns:1fr; gap:24px; padding:22px; }
  .archive-project .proj_chars { gap:16px; }
  .zam-content-row { grid-template-columns:1fr; gap:28px; }
  .zam-content-sections { grid-template-columns:1fr; gap:20px; }
  .zam-content-row { padding-top:28px; }
  .zam-copy-section { padding:24px; }
  .zam-content-photo { position:static; max-width:640px; }
  .zam-content-photo img { max-height:480px; object-fit:cover; }
  .contacts .conts_block { width:100%; padding-bottom:12px; }
  .contacts .map { position:static; height:auto; min-height:0; width:100%; margin-top:24px; }
  .contacts .map:empty { display:none; }
  .contacts .map iframe, .contacts .map ymaps { width:100%; max-width:100%; height:300px; }
  .contacts, .contacts-page { min-height:0; height:auto; }
  .contacts .wrapper { min-height:0; }
  .contacts .cont_text { line-height:1.55; }
  .cont_row { gap:24px; }
  .cont_row > .conts_block, .cont_row > .wpcf7 { width:100%; }
  .zam-project-gallery { gap:14px; margin-bottom:36px; }
  .zam-project-facts { padding:24px; }
  #port_slider { padding:22px; }
  #port_slider .port_block { gap:20px; }
  #port_slider .port_info { padding-bottom:0; }
  #port_slider > .owl-controls .owl-buttons { flex-wrap:wrap; justify-content:center; }
}
@media(max-width:560px) {
  .zam-cookie-notice { left:10px; right:10px; bottom:10px; flex-direction:column; align-items:flex-start; gap:12px; padding:16px; }
  .zam-services-grid, .blog_row, .zam-project-facts .proj_chars { grid-template-columns:1fr; }
  .zam-services-grid { gap:24px; }
  .zam-service-copy { padding:22px; }
  .zam-content-rows { gap:40px; }
  .zam-rich-copy { font-size:17px; line-height:1.65; }
  .zam-project-gallery { grid-template-columns:1fr; }
  .zam-gallery-photo:not(:first-child) img { aspect-ratio:auto; }
  .zam-gallery-photo:first-child img { aspect-ratio:4/3; }
  .zam-lightbox { width:100vw; max-width:100vw; height:96vh; padding-inline:8px; padding-bottom:60px; }
  .zam-lightbox-prev, .zam-lightbox-next { top:auto; bottom:8px; }
  .zam-lightbox-prev { left:calc(50% - 60px); }
  .zam-lightbox-next { right:calc(50% - 60px); }
  .usl_line { flex-direction:column; gap:24px; }
  .usl_cena { font-size:26px; margin:0; text-align:center; }
}
@media(prefers-reduced-motion:reduce) { .zam-service-photo img { transition:none; } }
