/*
Theme Name: Csabai Műkő
Theme URI: https://csabaimuko.hu
Author: Csabai Műkő
Description: A Csabai Műkő egyedi blokktémája. Letisztult, képközpontú főoldal, Termékek és Szolgáltatások aloldal, szerkeszthető szövegekkel és cserélhető képekkel.
Version: 1.0.0
Requires at least: 6.6
Tested up to: 7.1
Requires PHP: 8.2
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: csabaimuko
*/

:root{
  --white:#ffffff;
  --mist:#f2f4f6;
  --ink:#10171e;
  --blue:#1c3349;
  --ochre:#c39a4a;
  --muted:#69727b;
  --line:#dde1e5;
  --serif:"Instrument Serif","Iowan Old Style","Palatino Linotype",Georgia,serif;
  --sans:"Instrument Sans",system-ui,-apple-system,"Segoe UI",sans-serif;
}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{margin:0;background:var(--white);color:var(--ink);font-family:var(--sans);font-size:17px;line-height:1.65;-webkit-font-smoothing:antialiased;overflow-x:hidden}
a{color:inherit;text-decoration:none}
p{margin:0}
img{display:block;max-width:100%;height:auto}
h1,h2,h3{font-family:var(--serif);font-weight:400;margin:0;letter-spacing:-.012em;text-wrap:balance}
.wp-block-image{margin:0}
.wrap{max-width:1200px;margin:0 auto;padding:0 40px}
.label{font-size:12px;font-weight:500;letter-spacing:.16em;text-transform:uppercase;color:var(--muted)}
:focus-visible{outline:2px solid var(--ochre);outline-offset:4px}

/* ===== fejléc ===== */
.site-header{background:rgba(255,255,255,.62);-webkit-backdrop-filter:blur(16px) saturate(120%);backdrop-filter:blur(16px) saturate(120%);border-bottom:1px solid rgba(16,23,30,.1)}
.site-header .wrap{display:flex;align-items:center;justify-content:space-between;gap:24px;height:96px}
.brand{display:flex;align-items:center;gap:14px}
.brand-logo a{display:block}
.brand-logo img{width:36px;height:36px}
.brand-name{font-family:var(--serif);font-size:26px;line-height:1.2}
.site-header .wp-block-navigation{font-size:15px;font-weight:500}
.site-header .wp-block-navigation .wp-block-navigation__container{gap:40px}
.site-header .wp-block-navigation .wp-block-navigation-item__content{padding:6px 0;border-bottom:1px solid transparent;transition:border-color .2s}
.site-header .wp-block-navigation .wp-block-navigation-item__content:hover,
.site-header .wp-block-navigation .wp-block-navigation-item__content[aria-current],
.site-header .wp-block-navigation .current-menu-item>.wp-block-navigation-item__content{border-bottom-color:var(--ink)}
/* a főoldalon a fejléc a nyitókép fölött áll */
body.home:not(.editor-styles-wrapper) .site-header{position:absolute;top:0;left:0;right:0;z-index:5}
body.home:not(.editor-styles-wrapper) .hero{padding-top:97px}

/* ===== nyitó rész ===== */
.hero{position:relative;isolation:isolate;min-height:min(600px,80vh);display:flex;flex-direction:column;color:var(--ink);background:#e9ebec;overflow:hidden}
.hero-bg{position:relative}
.hero-bg::after{content:"";position:absolute;inset:0;background:linear-gradient(90deg,rgba(255,255,255,.94) 0%,rgba(255,255,255,.88) 36%,rgba(255,255,255,.3) 68%,rgba(255,255,255,0) 100%)}
body:not(.editor-styles-wrapper) .hero-bg{position:absolute;inset:0;z-index:-1}
body:not(.editor-styles-wrapper) .hero-bg img{width:100%;height:100%;object-fit:cover}
body .hero-body{margin:auto 0;padding:44px 0 64px;width:100%}
.hero .label{display:flex;align-items:center;gap:16px;margin-bottom:22px}
.hero .label::before{content:"";width:48px;height:1px;background:var(--ochre)}
.hero h1{font-size:clamp(44px,6.6vw,96px);line-height:1.04;max-width:14ch}
.hero .hero-text{font-size:20px;line-height:1.6;max-width:520px;margin-top:24px;color:#2c353d}

/* ===== rólunk, képváltóval ===== */
.about{padding:64px 0}
.about .wrap{display:grid;grid-template-columns:5fr 6fr;gap:60px;align-items:center}
.about .big{font-family:var(--serif);font-size:clamp(26px,2.7vw,36px);line-height:1.3;margin:28px 0 0}
body .values{margin-top:32px;border-top:1px solid var(--line)}
.value{display:grid;grid-template-columns:170px 1fr;gap:24px;padding:14px 0;border-bottom:1px solid var(--line);align-items:baseline}
.value h3{font-size:24px}
.value p{font-size:15.5px;color:#48525b}

/* a képváltó az oldalon; a szerkesztőben sima galéria marad, hogy könnyű legyen kezelni */
body:not(.editor-styles-wrapper) .csm-slider.wp-block-gallery{display:block!important;position:relative;aspect-ratio:5/6;overflow:hidden;background:var(--mist);margin:0 0 0 max(-64px,min(0px,calc((1160px - 100vw) / 2)));touch-action:pan-y}
body:not(.editor-styles-wrapper) .csm-slider.wp-block-gallery figure.wp-block-image{position:absolute!important;inset:0;width:100%!important;height:100%;margin:0!important;opacity:0;transition:opacity .9s ease}
body:not(.editor-styles-wrapper) .csm-slider.wp-block-gallery figure.wp-block-image img{width:100%!important;height:100%!important;object-fit:cover}
body:not(.editor-styles-wrapper) .csm-slider.wp-block-gallery figure.wp-block-image figcaption{display:none}
body:not(.editor-styles-wrapper) .csm-slider:not(.is-ready) figure.wp-block-image:first-of-type,
body:not(.editor-styles-wrapper) .csm-slider figure.wp-block-image.on{opacity:1}
body:not(.editor-styles-wrapper) .csm-slider:not(:has(img)){display:none!important}
body:not(.editor-styles-wrapper) .about .wrap:not(:has(.csm-slider img)){grid-template-columns:1fr}
.csm-slider button{position:absolute;top:50%;transform:translateY(-50%);z-index:2;width:44px;height:42%;min-height:120px;border:0;border-radius:0;padding:0;background:rgba(255,255,255,.78);color:var(--ink);font-family:inherit;font-size:20px;line-height:1;cursor:pointer;transition:background .2s}
.csm-slider button:hover{background:#fff}
.csm-slider .prev{left:0}
.csm-slider .next{right:0}
.csm-slider .count{position:absolute;left:20px;bottom:18px;z-index:2;font-size:13px;font-weight:500;letter-spacing:.08em;color:#fff;text-shadow:0 1px 6px rgba(0,0,0,.6)}

/* ===== két nagy blokk ===== */
.doors{display:grid;grid-template-columns:1fr 1fr;gap:2px;background:#fff}
.door{position:relative;isolation:isolate;display:flex;flex-direction:column;justify-content:flex-end;min-height:620px;padding:48px;color:#fff;overflow:hidden;background:#0c1116}
.door-bg{position:relative}
.door-bg::after{content:"";position:absolute;inset:0;background:linear-gradient(180deg,rgba(8,12,16,0) 0%,rgba(8,12,16,.12) 14%,rgba(8,12,16,.66) 40%,rgba(8,12,16,.86) 100%)}
body:not(.editor-styles-wrapper) .door-bg{position:absolute;inset:0;z-index:-1}
body:not(.editor-styles-wrapper) .door-bg img{width:100%;height:100%;object-fit:cover;transition:transform 1.2s cubic-bezier(.2,.7,.2,1)}
.door:first-child .door-bg img{object-position:12% 50%}
.door:hover .door-bg img{transform:scale(1.04)}
.door .label{font-size:12px;color:rgba(255,255,255,.7)}
.door h2{font-size:clamp(52px,6vw,88px);line-height:1;margin:16px 0 18px}
.door p{max-width:440px;font-size:18px;color:rgba(255,255,255,.86)}
.door ul{list-style:none;margin:22px 0 0;padding:0;font-size:15.5px;display:grid;grid-template-columns:1fr 1fr;column-gap:32px}
.door li{padding:13px 0;border-top:1px solid rgba(255,255,255,.28)}
.door .go{display:flex;align-items:center;justify-content:space-between;max-width:none;margin-top:24px;font-weight:600;font-size:16px;color:#fff}
.door .go::after{content:"→";display:grid;place-items:center;width:56px;height:56px;border:1px solid #fff;border-radius:50%;font-size:20px;font-weight:400;transition:transform .35s cubic-bezier(.2,.7,.2,1),background .35s,color .35s}
.door:hover .go::after{transform:translateX(8px);background:#fff;color:var(--ink)}
/* az egész blokk kattintható */
body:not(.editor-styles-wrapper) .door .go a::before{content:"";position:absolute;inset:0;z-index:1}

/* ===== kapcsolat ===== */
.cta{padding:68px 0 64px;text-align:center;background:var(--mist)}
.cta h2{font-size:clamp(38px,5vw,72px);line-height:1.06;max-width:16ch;margin:18px auto 18px}
.cta p{max-width:520px;margin:0 auto;color:#48525b}
.cta .label{color:var(--muted);max-width:none}
body .reach{display:flex;justify-content:center;gap:72px;margin-top:36px;flex-wrap:wrap}
.reach .reach-val{max-width:none;margin-top:8px;color:var(--ink)}
.reach .reach-val a{display:inline-block;font-family:var(--serif);font-size:34px;line-height:1.3;border-bottom:1px solid var(--ochre);padding-bottom:4px}
.reach .reach-val a:hover{color:var(--blue)}

/* ===== lábléc ===== */
.site-footer{background:var(--ink);color:#8b96a0;padding:32px 0;font-size:14px}
.site-footer .wrap{display:flex;justify-content:space-between;gap:16px;flex-wrap:wrap}

/* ===== aloldalak: Termékek, Szolgáltatások ===== */
.intro{padding:56px 0 64px}
.intro .wrap{display:grid;grid-template-columns:6fr 5fr;gap:60px;align-items:center}
.intro h1{font-size:clamp(44px,5.4vw,76px);line-height:1.04;margin:18px 0 24px}
.intro .lead{font-family:var(--serif);font-size:clamp(22px,2.2vw,29px);line-height:1.35}
.intro .more{margin-top:20px;color:#48525b;max-width:520px}
.intro .intro-img img{width:100%;aspect-ratio:5/4;object-fit:cover}
.prices{padding:64px 0;background:var(--mist)}
.prices .wrap{display:grid;grid-template-columns:5fr 6fr;gap:60px;align-items:start}
.prices h2,.folio h2{font-size:clamp(34px,4vw,54px);line-height:1.08;margin:16px 0 20px}
.prices-text p{color:#48525b;max-width:440px}
.prices-text p+p{margin-top:14px}
.prices-text .label{color:var(--muted)}
.rows{border-top:1px solid #cfd5da}
.row{display:grid;grid-template-columns:1fr auto;column-gap:24px;align-items:baseline;padding:16px 0;border-bottom:1px solid #cfd5da}
.row h3{font-size:24px;grid-row:1 / span 2}
.row .amount{font-weight:500;white-space:nowrap;text-align:right}
.row .unit{font-size:13px;color:var(--muted);text-align:right;grid-column:2}
.folio{padding:64px 0}
body .folio-head{display:flex;justify-content:space-between;align-items:flex-end;gap:24px;flex-wrap:wrap;margin-bottom:28px}
.folio-head h2{margin-bottom:0}
.folio-note{color:#48525b;max-width:380px;font-size:15.5px}
/* portfólió: annyi kép, amennyi fel van töltve; üresen nem látszik semmi */
body:not(.editor-styles-wrapper) .csm-grid.wp-block-gallery{display:grid!important;grid-template-columns:repeat(3,1fr);gap:12px!important;margin:0}
body:not(.editor-styles-wrapper) .csm-grid.wp-block-gallery figure.wp-block-image{width:100%!important;margin:0!important;display:block}
body:not(.editor-styles-wrapper) .csm-grid.wp-block-gallery figure.wp-block-image img{width:100%!important;height:auto!important;aspect-ratio:4/3;object-fit:cover;flex:none}
body:not(.editor-styles-wrapper) .csm-grid:not(:has(img)){display:none!important}

/* ===== általános oldalak (ha valaki sima oldalt vagy bejegyzést készít) ===== */
.plain{padding:56px 0 64px}
.plain h1{font-size:clamp(38px,5vw,64px);line-height:1.06;margin-bottom:24px}
.plain p{margin-top:14px}

@media (max-width:900px){
  .wrap{padding:0 24px}
  .site-header .wrap{height:80px}
  .site-header .wp-block-navigation{font-size:14px}
  .site-header .wp-block-navigation .wp-block-navigation__container{gap:22px}
  body.home:not(.editor-styles-wrapper) .hero{padding-top:81px}
  .hero{min-height:470px}
  .hero-bg::after{background:linear-gradient(180deg,rgba(255,255,255,.8) 0%,rgba(255,255,255,.86) 60%,rgba(255,255,255,.55) 100%)}
  .door-bg::after{background:linear-gradient(180deg,rgba(8,12,16,.42) 0%,rgba(8,12,16,.7) 40%,rgba(8,12,16,.86) 100%)}
  .hero-body{padding:36px 0 48px}
  .about{padding:44px 0}
  .about .wrap{grid-template-columns:1fr;gap:26px}
  body:not(.editor-styles-wrapper) .csm-slider.wp-block-gallery{aspect-ratio:4/3;margin-left:0}
  .doors{grid-template-columns:1fr}
  .door{min-height:430px;padding:34px 24px}
  .cta{padding:48px 0}
  .reach{gap:36px}
  .reach .reach-val a{font-size:26px}
  .intro{padding:40px 0 44px}
  .intro .wrap,.prices .wrap{grid-template-columns:1fr;gap:28px}
  .prices,.folio{padding:44px 0}
  body:not(.editor-styles-wrapper) .csm-grid.wp-block-gallery{grid-template-columns:repeat(2,1fr);gap:8px!important}
}
@media (max-width:520px){
  body{font-size:16px}
  .wrap{padding:0 16px}
  .brand-name{font-size:21px}
  .brand-logo img{width:30px;height:30px}
  .site-header .wrap{height:auto;flex-wrap:wrap;row-gap:4px;padding-top:12px;padding-bottom:10px}
  .site-header .wp-block-navigation{width:100%}
  .site-header .wp-block-navigation .wp-block-navigation__container{width:100%;justify-content:space-between;gap:10px;flex-wrap:nowrap}
  body.home:not(.editor-styles-wrapper) .hero{padding-top:92px}
  .value{grid-template-columns:1fr;gap:4px}
  .door{padding:40px 16px}
  .door ul{grid-template-columns:1fr}
  .row{grid-template-columns:1fr}
  .row h3{grid-row:auto}
  .row .amount,.row .unit{text-align:left;grid-column:1}
  .reach .reach-val a{font-size:23px}
}
@media (prefers-reduced-motion:reduce){*{transition:none!important}html{scroll-behavior:auto}}
