/* Page blocks. Neutral defaults; each theme sets --th-* tokens and overrides below. */
.blocks {
    --b-bg: var(--th-bg, var(--brand-background, #fff));
    --b-surface: var(--th-surface, #fff);
    --b-text: var(--th-text, var(--brand-text, #111827));
    --b-muted: var(--th-muted, #6b7280);
    --b-border: var(--th-border, rgba(0, 0, 0, .1));
    --b-accent: var(--th-accent, var(--brand-primary, #2563eb));
    --b-btn: var(--th-btn, var(--brand-btn-background, var(--brand-primary, #111827)));
    --b-btn-text: var(--th-btn-text, #fff);
    --b-radius: var(--th-radius, 16px);
    --b-heading: var(--th-font-heading, inherit);
    color: var(--b-text);
    background: var(--b-bg);
}

.blocks .blk-wrap { max-width: 1120px; margin: 0 auto; padding: 0 22px; }
.blocks .blk { padding: 76px 0; }
.blocks h1, .blocks h2, .blocks h3 { font-family: var(--b-heading); margin: 0; line-height: 1.12; }
.blocks h2 { font-size: clamp(1.7rem, 3.4vw, 2.5rem); margin-bottom: 18px; }
.blocks p { line-height: 1.75; color: var(--b-muted); margin: 0 0 16px; }

.blocks .blk-btn {
    display: inline-block; padding: 13px 28px; border: 0; cursor: pointer; text-decoration: none;
    background: var(--b-btn); color: var(--b-btn-text); font-weight: 700; border-radius: var(--th-btn-radius, 999px);
    font-size: .95rem; transition: transform .15s, opacity .15s;
}
.blocks .blk-btn:hover { transform: translateY(-2px); opacity: .92; }

/* hero */
.blocks .blk-hero {
    min-height: 74vh; display: flex; align-items: center; color: #fff; background-size: cover; background-position: center;
    background-color: var(--b-accent); background-image: linear-gradient(135deg, var(--b-accent), #0f172a);
    position: relative;
}
.blocks .blk-hero[style*="url"]::before { content: ""; position: absolute; inset: 0; background: rgba(0, 0, 0, .45); }
.blocks .blk-hero .blk-wrap { position: relative; width: 100%; }
.blocks .blk-hero h1 { font-size: clamp(2.3rem, 6vw, 4.4rem); font-weight: 800; max-width: 820px; }
.blocks .blk-hero p { color: rgba(255, 255, 255, .88); font-size: 1.15rem; max-width: 620px; margin: 18px 0 28px; }
.blocks .blk-hero .blk-btn { background: #fff; color: #111827; }

/* text */
.blocks .blk-text .blk-wrap { max-width: 800px; }

/* image + text */
.blocks .blk-imgtext .blk-wrap { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.blocks .blk-imgtext.is-left .blk-imgtext-img { order: -1; }
.blocks .blk-imgtext-img img { width: 100%; border-radius: var(--b-radius); display: block; object-fit: cover; max-height: 460px; }

/* features */
.blocks .blk-features { background: var(--b-surface); }
.blocks .blk-features h2 { text-align: center; margin-bottom: 40px; }
.blocks .blk-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 24px; }
.blocks .blk-grid article { padding: 28px; border: 1px solid var(--b-border); border-radius: var(--b-radius); background: var(--b-bg); }
.blocks .blk-grid .material-icons { color: var(--b-accent); font-size: 2.1rem; }
.blocks .blk-grid h3 { font-size: 1.2rem; margin: 12px 0 8px; }
.blocks .blk-grid p { margin: 0; }

/* gallery */
.blocks .blk-gallery h2 { text-align: center; margin-bottom: 32px; }
.blocks .blk-gallery-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.blocks .blk-gallery-grid img { width: 100%; aspect-ratio: 4/3; object-fit: cover; border-radius: var(--b-radius); }

/* faq */
.blocks .blk-faq .blk-wrap { max-width: 800px; }
.blocks .blk-faq details { border-bottom: 1px solid var(--b-border); padding: 16px 0; }
.blocks .blk-faq summary { cursor: pointer; font-weight: 700; font-size: 1.05rem; }
.blocks .blk-faq details p { margin: 12px 0 0; }

/* cta */
.blocks .blk-cta { text-align: center; background: var(--b-accent); color: #fff; }
.blocks .blk-cta p { color: rgba(255, 255, 255, .88); max-width: 560px; margin: 0 auto 24px; }
.blocks .blk-cta .blk-btn { background: #fff; color: #111827; }

/* contact */
.blocks .blk-contact .blk-wrap { max-width: 680px; }
.blocks .blk-form { display: grid; gap: 12px; margin-top: 18px; }
.blocks .blk-form input, .blocks .blk-form textarea {
    width: 100%; padding: 13px 15px; border-radius: calc(var(--b-radius) * .6); border: 1px solid var(--b-border);
    background: var(--b-surface); color: var(--b-text);
}
.blocks .blk-form .blk-btn { justify-self: start; }
.blocks .blk-ok { background: #ecfdf5; color: #065f46; padding: 10px 14px; border-radius: 10px; }
.blocks .blk-err { background: #fef2f2; color: #991b1b; padding: 10px 14px; border-radius: 10px; }

@media (max-width: 768px) {
    .blocks .blk { padding: 52px 0; }
    .blocks .blk-imgtext .blk-wrap { grid-template-columns: 1fr; gap: 26px; }
    .blocks .blk-imgtext.is-left .blk-imgtext-img { order: 0; }
}

/* Live products + services blocks (all block themes) */
.blocks .blk-lead { text-align: center; max-width: 640px; margin: 0 auto 32px; opacity: .8; }
.blocks .blk-products h2, .blocks .blk-services h2 { text-align: center; margin: 0 0 28px; }
.blocks .blk-products-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 28px 22px; }
.blocks .blk-product { display: flex; flex-direction: column; gap: 6px; text-decoration: none; color: inherit; }
.blocks .blk-product-img { display: block; aspect-ratio: 3 / 4; overflow: hidden; background: #f1f1ee; }
.blocks .blk-product-img img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .5s ease; }
.blocks .blk-product:hover .blk-product-img img { transform: scale(1.05); }
.blocks .blk-product-name { margin-top: 8px; font-weight: 500; }
.blocks .blk-product-price { opacity: .7; font-size: .92rem; }
.blocks .blk-center { text-align: center; margin-top: 40px; }
.blocks .blk-services-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 24px; }
.blocks .blk-service { display: flex; flex-direction: column; gap: 8px; padding: 32px 28px; border: 1px solid var(--th-border, #e5e5e5); text-decoration: none; color: inherit; transition: transform .25s, box-shadow .25s; background: var(--th-surface, transparent); }
.blocks .blk-service:hover { transform: translateY(-4px); box-shadow: 0 16px 40px rgba(0, 0, 0, .08); }
.blocks .blk-service .material-icons { font-size: 2.2rem; }
.blocks .blk-service h3 { margin: 6px 0 0; }
.blocks .blk-service p { margin: 0; opacity: .75; flex: 1; }
.blocks .blk-service-cta { margin-top: 10px; text-transform: uppercase; letter-spacing: .14em; font-size: .72rem; font-weight: 600; }
