/*
Theme Name: ЧеБрусчатка Казань
Theme URI: https://kazan.chebrus.ru/
Author: ЧеБрусчатка
Description: Изолированная тема для казанского сайта WordPress Multisite. Сохраняет существующие записи, страницы и WooCommerce.
Version: 0.3.5
Text Domain: chebrus-kazan
Requires at least: 6.0
Requires PHP: 7.4
*/
.chebrus-wp-content { padding-top: clamp(36px,6vw,72px); padding-bottom: clamp(56px,8vw,96px); min-height: 45vh; }
.chebrus-trap { position: absolute!important; width: 1px!important; height: 1px!important; opacity: 0!important; pointer-events: none!important; }
.skip-link { position: absolute; transform: translateY(-150%); z-index: 500; background: #fff; color: #201b16; padding: 10px 18px; }
.skip-link:focus { transform: translateY(0); }
.chebrus-wp-content .article-body img, .chebrus-wp-content .article-body iframe { max-width: 100%; height: auto; }
.chebrus-preserved { padding-block: 40px; }
.content-card-grid,.shop-card-grid { display:grid; grid-template-columns:minmax(0,1fr); gap:20px; margin-top:24px; }
.content-card,.shop-card { min-width:0; display:flex; flex-direction:column; overflow:hidden; color:inherit; text-decoration:none; background:var(--bg); border:1px solid var(--line-15); border-radius:var(--r-card); transition:transform .18s ease,border-color .18s ease,box-shadow .18s ease; }
.content-card:hover,.shop-card:hover { color:inherit; transform:translateY(-3px); border-color:var(--line-2); box-shadow:0 14px 34px rgba(43,38,32,.10); }
.content-card:focus-visible,.shop-card:focus-visible { outline:3px solid var(--accent); outline-offset:4px; }
.content-card__media,.shop-card__media { display:block; background:#fff; aspect-ratio:4/3; overflow:hidden; }
.content-card__media img,.shop-card__media img { display:block; width:100%; height:100%; object-fit:cover; }
.shop-card__media img { object-fit:contain; }
.content-card__placeholder { display:block; width:100%; height:100%; background:linear-gradient(135deg,var(--bg-2),var(--bg-3)); }
.content-card__body,.shop-card__body { display:flex; flex:1; flex-direction:column; gap:10px; padding:20px; }
.content-card__eyebrow { color:var(--text-muted); font-size:12px; font-weight:650; letter-spacing:.08em; text-transform:uppercase; }
.content-card__title,.shop-card__body strong { font:600 clamp(17px,2vw,21px)/1.3 var(--font-sans); }
.content-card__action,.shop-card__action { margin-top:auto; padding-top:8px; color:var(--brand); font-weight:650; }
.shop-card__price { color:var(--text); font-weight:600; }
.lead-send-error { color: var(--on-dark); grid-column: 1 / -1; border-left: 3px solid var(--accent); padding-left: 12px; }
.lead-form[hidden] { display: none; }
.lead-modal__title { color: var(--on-dark); }
.site-footer .site-footer__logo { width: 210px; max-width: 100%; height: auto; }
.chebrus-wp-content .article-body { overflow-wrap: anywhere; }
.chebrus-wp-content .article-body table:not(.wc-block-cart-items):not(.shop_table) { display: block; max-width: 100%; overflow-x: auto; }
.chebrus-wp-content input, .chebrus-wp-content textarea, .chebrus-wp-content select { max-width: 100%; font: inherit; }
.chebrus-wp-content textarea { width: 100%; }
.comment-form label { display: block; margin-top: 12px; }
.comment-form input:not([type=checkbox]), .comment-form textarea { padding: 10px; border: 1px solid var(--line-2); border-radius: var(--r-btn); }
.comment-form .submit { background: var(--accent); color: var(--on-accent); min-height: 44px; cursor: pointer; }
body.admin-bar .site-header { top: 32px; }
@media(max-width:782px) { body.admin-bar .site-header { top: 46px; } }

/* Native WordPress content: shared rhythm for migrated material/project pages. */
.chebrus-native-section { margin-block: clamp(24px,4vw,48px); }
.chebrus-native-column { min-width: 0; }
.chebrus-native-column > * + * { margin-top: 20px; }
.chebrus-native-grid { display: grid; grid-template-columns: minmax(0,1fr); gap: clamp(20px,3vw,40px); align-items: start; }
.chebrus-native-gallery { min-width:0; }
.chebrus-native-gallery > .wp-block-group__inner-container { display:flex; gap:16px; overflow-x:auto; padding:2px 2px 14px; scroll-snap-type:x mandatory; scrollbar-width:thin; scrollbar-color:var(--accent) var(--line); touch-action:pan-x pan-y; overscroll-behavior-inline:contain; -webkit-overflow-scrolling:touch; }
.chebrus-native-gallery .wp-block-image { margin: 0; }
.chebrus-native-gallery > .wp-block-group__inner-container > * { flex:0 0 min(86%,760px); scroll-snap-align:start; scroll-snap-stop:always; }
.chebrus-native-gallery img { display: block; width: 100%; aspect-ratio: 4/3; object-fit: contain; background: var(--bg-2, #f5f5f5); border-radius: var(--r-card, 8px); }
.chebrus-new-project { margin-top: clamp(24px,4vw,48px); }
.chebrus-new-project__lead { max-width: 760px; color: var(--muted); margin-bottom: 24px; }
.chebrus-preserved__archive-title { margin-top: clamp(48px,7vw,84px); }
.content-card-grid--new-projects { margin-bottom: 0; }
.chebrus-native-section .wp-block-video { margin: 0; }
.chebrus-native-section video { display: block; width: 100%; max-height: 70vh; aspect-ratio: 16/9; background: var(--dark); }
.chebrus-native-review { padding: clamp(20px,3vw,32px); border: 1px solid var(--line-2); border-radius: var(--r-card, 8px); }
.chebrus-native-review .wp-block-image { max-width: 160px; }
.chebrus-wp-content .wp-block-button__link { background: var(--accent); color: var(--on-accent); min-height: 44px; padding: 14px 22px; border-radius: var(--r-btn); font: inherit; text-decoration: none; }
.chebrus-wp-content .wp-block-button__link:hover { background: var(--accent-hover); }
.chebrus-wp-content .wp-block-button__link:focus-visible { outline: 3px solid var(--ink, #222); outline-offset: 4px; }
@media(min-width:768px) {
  .content-card-grid,.shop-card-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .chebrus-native-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .chebrus-native-grid > :only-child { grid-column: 1/-1; }
  .chebrus-native-gallery > .wp-block-group__inner-container > * { flex-basis:min(72%,760px); }
}
@media(min-width:1100px) {
  .content-card-grid--projects { grid-template-columns:repeat(3,minmax(0,1fr)); }
  .shop-card-grid { grid-template-columns:repeat(3,minmax(0,1fr)); }
}
@media(prefers-reduced-motion:reduce) { .content-card,.shop-card { transition:none; } }
