:root {
  --red: #e41d2f;
  --red-dark: #b8141f;
  --ink: #16181d;
  --ink-2: #4a4f5a;
  --muted: #7a808c;
  --line: #e7e8ec;
  --soft: #f5f6f8;
  --bg: #ffffff;
  --radius: 14px;
  --shadow: 0 10px 30px rgba(22, 24, 29, .08);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font); color: var(--ink); background: var(--bg); line-height: 1.55; font-size: 16px; }
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { line-height: 1.15; margin: 0; letter-spacing: -.01em; }
p { margin: 0; }
.wrap { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.muted { color: var(--muted); }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; background: var(--red); color: #fff; text-decoration: none; border: 0; border-radius: 999px; padding: 14px 26px; font: 600 15px/1.2 var(--font); cursor: pointer; transition: background .2s, transform .2s, box-shadow .2s; box-shadow: 0 8px 20px rgba(228, 29, 47, .25); }
.btn:hover { background: var(--red-dark); transform: translateY(-1px); }
.btn:disabled { opacity: .6; cursor: default; transform: none; }
.btn-sm { padding: 10px 18px; font-size: 14px; box-shadow: none; }
.btn-ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 2px var(--ink); }
.btn-ghost:hover { background: var(--ink); color: #fff; }
.btn-block { width: 100%; }

/* topbar + header */
.topbar { background: var(--ink); color: #c9ccd3; font-size: 13px; }
.topbar-in { display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 36px; flex-wrap: wrap; }
.topbar-links { display: flex; gap: 18px; flex-wrap: wrap; }
.topbar a { text-decoration: none; color: #fff; }
.topbar a:hover { color: #ff8d97; }
.header { position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, .94); backdrop-filter: saturate(160%) blur(10px); border-bottom: 1px solid var(--line); }
.header-in { display: flex; align-items: center; gap: 24px; height: 72px; }
.logo img { height: 44px; width: auto; max-width: 190px; object-fit: contain; }
.nav { display: flex; gap: 26px; margin-left: auto; }
.nav a { text-decoration: none; font-weight: 600; font-size: 15px; color: var(--ink-2); position: relative; padding: 6px 0; }
.nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--red); transform: scaleX(0); transition: transform .2s; }
.nav a:hover { color: var(--ink); }
.nav a:hover::after { transform: scaleX(1); }
.langs { display: inline-flex; background: var(--soft); border-radius: 999px; padding: 3px; }
.langs a { text-decoration: none; font-size: 13px; font-weight: 700; padding: 6px 10px; border-radius: 999px; color: var(--muted); }
.langs a.on { background: #fff; color: var(--red); box-shadow: 0 1px 4px rgba(0, 0, 0, .08); }
.burger { display: none; width: 44px; height: 44px; border: 0; background: none; cursor: pointer; position: relative; }
.burger span, .burger span::before, .burger span::after { position: absolute; left: 11px; width: 22px; height: 2px; background: var(--ink); content: ""; transition: transform .2s, top .2s; }
.burger span { top: 21px; }
.burger span::before { top: -7px; left: 0; }
.burger span::after { top: 7px; left: 0; }
.menu-open .burger span { background: transparent; }
.menu-open .burger span::before { top: 0; transform: rotate(45deg); }
.menu-open .burger span::after { top: 0; transform: rotate(-45deg); }

/* hero */
.hero { padding: 56px 0 64px; background: radial-gradient(1200px 500px at 90% -10%, rgba(228, 29, 47, .10), transparent 60%), linear-gradient(180deg, #fff, var(--soft)); }
.hero-in { display: grid; gap: 40px; }
.hero-text { display: grid; grid-template-columns: 1.1fr 1fr; gap: 12px 56px; align-items: end; }
.hero-text .eyebrow, .hero-text h1 { grid-column: 1; }
.hero-side { grid-column: 2; grid-row: 1 / span 2; align-self: end; }
.hero-side .lead { margin-top: 0; }
.eyebrow { display: inline-block; color: var(--red); font-weight: 700; text-transform: uppercase; letter-spacing: .12em; font-size: 13px; margin-bottom: 14px; }
.hero h1 { font-size: clamp(32px, 4.4vw, 52px); font-weight: 800; }
.lead { font-size: 18px; color: var(--ink-2); margin-top: 18px; max-width: 34em; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 28px; }
.hero-phones { display: flex; gap: 20px; margin-top: 26px; flex-wrap: wrap; }
.hero-phones a { font-weight: 700; text-decoration: none; font-size: 18px; }
.hero-phones a:hover { color: var(--red); }
.slider { position: relative; border-radius: 20px; overflow: hidden; box-shadow: var(--shadow); background: #fff; aspect-ratio: 10 / 3; }
.sl-btn { position: absolute; top: 50%; margin-top: -22px; width: 44px; height: 44px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .85); color: var(--ink); font-size: 26px; line-height: 1; cursor: pointer; z-index: 2; box-shadow: 0 4px 14px rgba(0, 0, 0, .12); transition: background .2s, color .2s; }
.sl-btn:hover { background: var(--red); color: #fff; }
.sl-prev { left: 14px; }
.sl-next { right: 14px; }
.slides { position: absolute; inset: 0; }
.slide { position: absolute; inset: 0; opacity: 0; transition: opacity .7s ease; }
.slide.on { opacity: 1; }
.slide img { width: 100%; height: 100%; object-fit: cover; }
.dots { position: absolute; bottom: 10px; left: 0; right: 0; display: flex; justify-content: center; gap: 6px; }
.dots button { width: 8px; height: 8px; border-radius: 99px; border: 0; padding: 0; background: rgba(255, 255, 255, .7); cursor: pointer; transition: width .3s, background .3s; box-shadow: 0 0 0 1px rgba(0, 0, 0, .1); }
.dots button.on { width: 22px; background: var(--red); }

/* sections */
.section { padding: 80px 0; }
.section-soft { background: var(--soft); }
.h2 { font-size: clamp(26px, 3vw, 38px); font-weight: 800; margin-bottom: 36px; position: relative; padding-left: 18px; }
.h2::before { content: ""; position: absolute; left: 0; top: .15em; bottom: .15em; width: 5px; border-radius: 4px; background: var(--red); }
.h2-center { text-align: center; padding-left: 0; max-width: 820px; margin-left: auto; margin-right: auto; }
.h2-center::before { display: none; }

/* services tiles */
.tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.tile { margin: 0; background: #fff; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); transition: transform .25s, box-shadow .25s; }
.tile:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.tile-img { aspect-ratio: 264 / 254; background: var(--soft); overflow: hidden; }
.tile-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.tile:hover .tile-img img { transform: scale(1.05); }
.tile figcaption { padding: 14px 16px; font-weight: 700; text-transform: uppercase; font-size: 14px; letter-spacing: .03em; }

/* directions */
.dirs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.dir { background: #fff; border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; border: 1px solid var(--line); }
.dir-img { aspect-ratio: 4 / 3; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #fff, #fdf0f1); padding: 18px; }
.dir-img img { max-height: 100%; width: auto; object-fit: contain; }
.dir-body { padding: 20px 22px 24px; }
.dir h3 { font-size: 18px; text-transform: uppercase; letter-spacing: .02em; margin-bottom: 10px; color: var(--red); }
.dir p { color: var(--ink-2); font-size: 15px; }

/* about + order */
.about { display: grid; grid-template-columns: 1.2fr 1fr; gap: 56px; align-items: start; }
.checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.checks li { position: relative; padding: 14px 18px 14px 54px; background: var(--soft); border-radius: 12px; font-size: 16px; }
.checks li::before { content: ""; position: absolute; left: 16px; top: 50%; width: 24px; height: 24px; margin-top: -12px; border-radius: 50%; background: var(--red) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4 8-9'/%3E%3C/svg%3E") center / 16px no-repeat; }
.order { background: #fff; border-radius: 20px; padding: 32px; box-shadow: var(--shadow); border: 1px solid var(--line); position: sticky; top: 96px; display: grid; gap: 14px; }
.order h3 { font-size: 26px; font-weight: 800; }
.order label { display: grid; gap: 6px; font-size: 14px; font-weight: 600; color: var(--ink-2); }
.order input, .order textarea { font: inherit; font-size: 16px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--soft); outline: none; transition: border-color .2s, background .2s; resize: vertical; }
.order input:focus, .order textarea:focus { border-color: var(--red); background: #fff; }
.order .invalid { border-color: var(--red); }
.order .hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.order-msg { padding: 12px 14px; border-radius: 10px; font-size: 15px; }
.order-msg.ok { background: #e8f7ee; color: #146c3a; }
.order-msg.err { background: #fdecee; color: var(--red-dark); }

/* portfolio */
.works { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.work { display: block; border-radius: 12px; overflow: hidden; aspect-ratio: 1; background: #e9eaee; cursor: zoom-in; }
.work img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s, filter .3s; }
.work:hover img { transform: scale(1.06); }

/* benefits */
.benefits { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.benefit { padding: 28px 24px; border-radius: var(--radius); border: 1px solid var(--line); background: #fff; transition: box-shadow .25s, transform .25s; }
.benefit:hover { box-shadow: var(--shadow); transform: translateY(-3px); }
.benefit-icon { width: 64px; height: 64px; object-fit: contain; margin-bottom: 18px; }
.benefit h3 { font-size: 17px; text-transform: uppercase; letter-spacing: .02em; margin-bottom: 10px; }
.benefit p { color: var(--ink-2); font-size: 15px; }

/* partners */
.partners-img { background: #fff; border-radius: 20px; padding: 24px; box-shadow: var(--shadow); }
.partners-img img { width: 100%; height: auto; }

/* contacts */
.contacts { background: var(--ink); color: #e9eaee; }
.contacts .h2 { color: #fff; }
.contacts-in { display: grid; grid-template-columns: 1.3fr 1fr; gap: 48px; align-items: center; }
.cdl { display: grid; grid-template-columns: 140px 1fr; gap: 18px 24px; margin: 0; }
.cdl dt { color: #9aa0ac; font-size: 14px; text-transform: uppercase; letter-spacing: .06em; padding-top: 2px; }
.cdl dd { margin: 0; font-size: 17px; }
.cdl .muted { color: #9aa0ac; }
.cdl a { color: #fff; text-decoration: none; border-bottom: 1px solid rgba(255, 255, 255, .25); }
.cdl a:hover { color: #ff8d97; border-color: #ff8d97; }
.cdl .links { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.contacts-cta { background: linear-gradient(135deg, var(--red), #8d0f19); border-radius: 20px; padding: 36px; display: grid; gap: 22px; justify-items: start; }
.contacts-cta .lead { color: #fff; margin: 0; font-size: 20px; font-weight: 600; }
.contacts-cta .btn { background: #fff; color: var(--red); box-shadow: none; }
.contacts-cta .btn:hover { background: #ffe8ea; }

/* footer */
.footer { background: #0e0f12; color: #8a909b; font-size: 14px; }
.footer-in { display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 64px; flex-wrap: wrap; padding-top: 12px; padding-bottom: 12px; }
.langs-foot { background: #1c1e23; }
.langs-foot a.on { background: #2b2e35; color: #fff; }

/* lightbox */
.lightbox { position: fixed; inset: 0; z-index: 100; background: rgba(10, 11, 14, .92); display: flex; align-items: center; justify-content: center; padding: 40px 64px; }
.lightbox[hidden] { display: none; }
.lightbox img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 8px; }
.lightbox button { position: absolute; background: rgba(255, 255, 255, .1); color: #fff; border: 0; width: 48px; height: 48px; border-radius: 50%; font-size: 30px; line-height: 1; cursor: pointer; }
.lightbox button:hover { background: var(--red); }
.lb-close { top: 16px; right: 16px; }
.lb-prev { left: 12px; top: 50%; margin-top: -24px; }
.lb-next { right: 12px; top: 50%; margin-top: -24px; }

/* edit mode (visible only to a logged-in admin) */
.edit-toggle { position: fixed; right: 18px; bottom: 18px; z-index: 90; background: var(--ink); color: #fff; border: 0; border-radius: 999px; padding: 12px 18px; font: 600 14px var(--font); cursor: pointer; box-shadow: 0 8px 24px rgba(0, 0, 0, .25); }
.edit-toggle.on { background: var(--red); }
body.editing [data-k] { outline: 2px dashed rgba(228, 29, 47, .55); outline-offset: 2px; cursor: pointer !important; }
body.editing [data-k]:hover { outline-color: var(--red); background-color: rgba(228, 29, 47, .06); }

/* responsive */
@media (max-width: 1080px) {
  .nav { gap: 18px; }
  .header-cta { display: none; }
  .tiles, .works { grid-template-columns: repeat(3, 1fr); }
  .dirs, .benefits { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
  .header-in { gap: 12px; height: 64px; }
  .logo img { height: 38px; }
  .burger { display: block; }
  .langs { margin-left: auto; }
  .nav { position: absolute; top: 64px; left: 0; right: 0; flex-direction: column; gap: 0; background: #fff; border-bottom: 1px solid var(--line); padding: 8px 20px 16px; display: none; box-shadow: var(--shadow); }
  .menu-open .nav { display: flex; }
  .nav a { padding: 12px 0; font-size: 17px; border-bottom: 1px solid var(--line); }
  .nav a::after { display: none; }
  .hero { padding: 36px 0 44px; }
  .hero-in, .about, .contacts-in { grid-template-columns: 1fr; gap: 32px; }
  .hero-text { grid-template-columns: 1fr; }
  .hero-side { grid-column: 1; grid-row: auto; }
  .hero-side .lead { margin-top: 6px; }
  .sl-btn { width: 34px; height: 34px; margin-top: -17px; font-size: 20px; }
  .slider { border-radius: 12px; }
  .order { position: static; }
  .section { padding: 56px 0; }
  .tiles, .works { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .tile figcaption { font-size: 13px; padding: 10px 12px; }
}
@media (max-width: 560px) {
  .wrap { padding: 0 16px; }
  .topbar-city, .topbar-links a[href^="mailto"] { display: none; }
  .topbar-in { justify-content: center; }
  .dirs, .benefits { grid-template-columns: 1fr; }
  .cdl { grid-template-columns: 1fr; gap: 4px; }
  .cdl dd { margin-bottom: 14px; }
  .order { padding: 22px; }
  .lightbox { padding: 64px 8px; }
  .lb-prev, .lb-next { top: auto; bottom: 12px; margin-top: 0; }
  .lb-prev { left: calc(50% - 60px); }
  .lb-next { right: calc(50% - 60px); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
