/* The calm-interior direction recorded in .impeccable/surfaces/index-html.md,
   for the home page (EN `/`, RU `/ru`) and the service pages generated by
   scripts/build-pages.mjs. Loaded after landing.css: the new parts use their
   own h- classes and the shared ones are only retuned under body.home. */

.home {
  --warm: #f7f5f1;
  --warm-line: #ebe6de;
  --blue-soft: #e3ecf6; /* the price field; secondary text on it is --shade-45 (5.4:1) */
  --muted-warm: #5f6672; /* --muted is 4.4:1 on --warm; this is 5.3:1 */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}
.home ::selection { background: var(--blue-60); color: var(--ink); }
.home :focus-visible { outline: 2px solid var(--shade-25); outline-offset: 3px; border-radius: 6px; }
.home a { text-underline-offset: 3px; }
.home .wrap, .home .topbar-in { max-width: 1200px; }

/* ---------- Hero ---------- */
.h-hero { padding: 28px 0 0; }
.h-hero-in {
  display: grid; grid-template-columns: minmax(0, 1fr) 52vw; align-items: center;
  min-height: min(78vh, 720px);
}
.h-copy { padding-block: 24px; padding-inline: max(24px, calc((100vw - 1200px) / 2 + 24px)) 48px; }
.h-copy h1 {
  font-size: clamp(34px, 3.5vw, 52px); line-height: 1.06; letter-spacing: -0.03em; text-wrap: balance;
}
.h-copy .lead { margin: 20px 0 0; font-size: 18px; line-height: 1.6; color: var(--ink-2); max-width: 30em; }
.h-price { margin: 26px 0 0; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; }
.h-price b { font-family: var(--font-display); font-weight: 600; font-size: 22px; letter-spacing: -0.01em; }
.h-price span { font-size: 14.5px; color: var(--shade-45); }
.h-price b span { font-size: inherit; color: inherit; }
.h-cta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; margin-top: 22px; }
.h-wa {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 4px;
  font-weight: 500; font-size: 15px; color: var(--ink); text-decoration: none;
}
.h-wa .ico { color: #25d366; }
.h-wa:hover { text-decoration: underline; }
.h-note { margin: 18px 0 0; font-size: 13.5px; color: var(--muted); }

.h-photo { margin: 0; align-self: stretch; overflow: hidden; border-start-start-radius: var(--r-lg); border-end-start-radius: var(--r-lg); }
.h-photo img {
  display: block; width: 100%; height: 100%; object-fit: cover; object-position: 64% 50%;
  animation: h-settle 1.6s var(--ease-out) both;
}
/* The one moment of motion: the room settles into place as the page opens.
   It starts from a visible frame, so nothing waits on it. */
@keyframes h-settle { from { transform: scale(1.045); } }
/* The home photograph shows the work itself: the tool on the sofa. */
.home:not(.service) .h-photo img { object-position: 50% 60%; }

/* ---------- Promises ---------- */
.h-promises { margin-top: 8px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.h-promises ul { list-style: none; max-width: 1200px; margin: 0 auto; padding: 0 24px; display: grid; grid-template-columns: repeat(4, 1fr); }
.h-promises li { padding-block: 26px; padding-inline: 0 24px; }
.h-promises li + li { padding-inline-start: 24px; border-inline-start: 1px solid var(--line); }
.h-promises b { display: block; font-family: var(--font-display); font-weight: 600; font-size: 15.5px; letter-spacing: -0.01em; }
.h-promises span { display: block; margin-top: 6px; font-size: 14px; line-height: 1.55; color: var(--muted); }
.h-promises li { display: flex; gap: 12px; align-items: flex-start; }
.h-promises li .ico {
  flex: none; width: 32px; height: 32px; padding: 7px; border-radius: 10px;
  background: var(--blue-85); color: var(--shade-45);
}

/* ---------- What we clean: the shelf ---------- */
/* The services as the booking page draws them, each a tap from being in the
   basket (booking.html reads ?add=). */
.h-shelf { padding: 48px 0 40px; }
.h-shelf h2 { font-size: clamp(22px, 2.4vw, 28px); letter-spacing: -0.02em; }
.shelf { list-style: none; margin: 18px 0 0; padding: 0; display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 12px; }
.shelf a {
  display: flex; flex-direction: column; gap: 2px; height: 100%; padding: 10px 10px 12px;
  background: #fff; border: 1px solid var(--line); border-radius: 20px; color: var(--ink); text-decoration: none;
  box-shadow: var(--shadow-sm); transition: transform .3s var(--ease-out), box-shadow .3s var(--ease-out), border-color .2s;
}
.shelf a:hover { transform: translateY(-2px); border-color: var(--blue-30); box-shadow: var(--shadow-md); }
.shelf a:active { transform: scale(.97); }
.shelf-art { display: grid; place-items: center; aspect-ratio: 4 / 3; margin-bottom: 8px; border-radius: 14px; background: var(--blue-85); overflow: hidden; }
.shelf-art img { width: 84%; height: 84%; object-fit: contain; filter: drop-shadow(0 3px 4px rgba(23, 25, 28, .12)); }
.shelf b { font-family: var(--font-display); font-weight: 600; font-size: 14.5px; line-height: 1.25; letter-spacing: -0.01em; }
.shelf span:last-child { font-size: 13px; color: var(--muted); }
.shelf-more { margin: 16px 0 0; font-size: 13.5px; color: var(--muted-warm); }
.shelf-more a { color: var(--ink-2); }

/* ---------- Section heads ---------- */
.home .sect { padding: 88px 0; }
.home .sect h2 { font-size: clamp(26px, 3.2vw, 40px); letter-spacing: -0.025em; text-wrap: balance; }
.home .sect-sub { font-size: 16px; line-height: 1.6; }

/* ---------- What we clean ---------- */
.svc { list-style: none; margin: 34px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.svc a { display: block; color: var(--ink); text-decoration: none; }
.svc img {
  display: block; width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover;
  border-radius: var(--r-lg); background: var(--warm);
  transition: transform .5s var(--ease-out), box-shadow .5s var(--ease-out);
}
.svc a:hover img { transform: translateY(-3px); box-shadow: 0 14px 34px rgba(76, 96, 118, .16); }
.svc-t { display: block; margin-top: 14px; font-family: var(--font-display); font-weight: 600; font-size: 17px; letter-spacing: -0.01em; }
.svc-p { display: block; margin-top: 3px; font-size: 14.5px; color: var(--muted); }
.svc a:hover .svc-t { text-decoration: underline; text-decoration-thickness: 1px; }

/* ---------- Prices ---------- */
.home #prices { background: var(--blue-soft); }
.home .sect h2.h-from { margin: 0; font-family: var(--font-display); font-weight: 600; font-size: clamp(30px, 4.4vw, 52px); line-height: 1.05; letter-spacing: -0.03em; }
.home #prices .sect-sub { color: var(--shade-45); max-width: 40em; }
.home #prices .price-card { border-color: transparent; box-shadow: var(--shadow-sm); }
.home #prices .quote-box { background: var(--card); border-color: transparent; }
.home #prices .quote-box p { color: var(--muted); }

/* ---------- How a visit goes ---------- */
.h-steps { list-style: none; margin: 40px 0 36px; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; }
.h-steps li { padding-top: 22px; border-top: 1px solid var(--ink); }
.h-steps .n { display: block; font-family: var(--font-display); font-weight: 500; font-size: 40px; line-height: 1; letter-spacing: -0.03em; color: var(--shade-25); }
.h-steps h3 { margin-top: 18px; font-size: 18px; letter-spacing: -0.015em; }
.h-steps p { margin: 10px 0 0; font-size: 15px; line-height: 1.65; color: var(--muted); }

/* ---------- Homes ---------- */
.home #homes { background: var(--warm); }
.h-homes { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; margin-top: 36px; }
.h-homes figure { margin: 0; }
.h-homes img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; border-radius: var(--r-lg); }
.h-homes h3 { margin-top: 20px; font-size: 19px; letter-spacing: -0.015em; }
.h-homes p { margin: 8px 0 0; font-size: 15px; line-height: 1.65; color: var(--muted-warm); max-width: 34em; }

/* ---------- Why ---------- */
.home .why-grid { grid-template-columns: 1fr 1fr; gap: 0 56px; margin-top: 30px; }
.home .why { padding: 24px 0 26px; border-top: 1px solid var(--line); }
.home .why h3 { font-size: 18px; letter-spacing: -0.015em; }
.home .why p { font-size: 15px; }

/* ---------- Areas, FAQ ---------- */
.home #areas { background: var(--warm); }
.home #areas .sect-sub { color: var(--muted-warm); }
.home .areas li { border-color: var(--warm-line); }

/* ---------- Closer ---------- */
.h-close { padding: 72px 0; background: var(--blue); }
.h-close-in { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 56px; align-items: center; }
.h-close h2 { font-size: clamp(28px, 3.6vw, 46px); line-height: 1.08; letter-spacing: -0.03em; text-wrap: balance; }
.h-close p { margin: 14px 0 0; font-size: 17px; color: var(--ink-2); max-width: 32em; text-wrap: pretty; }
.h-close .h-cta { margin-top: 28px; }
.h-close :focus-visible { outline-color: var(--ink); } /* --shade-25 is 1.7:1 on the brand blue */
.h-close .btn.ghost { border-color: transparent; }
.h-close .btn.ghost:hover { background: var(--blue-85); }
.h-close figure { margin: 0; }
.h-close img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--r-lg); }

.home .foot { background: var(--warm); border-top-color: var(--warm-line); }
.home .foot p { color: var(--muted-warm); }
.home .foot .h-illus { margin-top: 6px; font-size: 12.5px; }

/* ---------- Service pages (scripts/build-pages.mjs) ---------- */
.service .h-copy .crumbs { margin-bottom: 18px; }
.home .sect.alt { background: var(--warm); }
.home .sect.alt .why { border-top-color: var(--warm-line); }
.home .sect.alt .why p { color: var(--muted-warm); }
.home .why-grid.three { grid-template-columns: repeat(3, 1fr); gap: 0 40px; margin-top: 0; }
.svc.three { grid-template-columns: repeat(3, 1fr); }
.home .sect.alt .svc-p { color: var(--muted-warm); }

/* ---------- Phone dock ---------- */
/* On a phone the header has no room for the booking button, so once the
   hero's button scrolls away this bar carries it until the closing block. */
.h-dock { display: none; }

/* ---------- Narrow ---------- */
@media (max-width: 900px) {
  .h-hero { padding: 0; }
  .h-hero-in { grid-template-columns: 1fr; min-height: 0; }
  .h-photo { order: -1; border-radius: 0; aspect-ratio: 16 / 11; }
  .h-photo img { object-position: 70% 55%; }
  .h-copy { padding: 22px 16px 0; }
  .h-copy h1 { font-size: clamp(28px, 7.6vw, 40px); line-height: 1.1; }
  .h-copy .lead { margin-top: 12px; font-size: 16px; line-height: 1.55; }
  .h-price { margin-top: 16px; }
  .h-price b { font-size: 19px; }
  .h-price span { font-size: 13.5px; }
  .h-cta { margin-top: 16px; }

  .h-promises { margin-top: 40px; }
  .h-promises ul { grid-template-columns: 1fr 1fr; padding: 0 16px; }
  .h-promises li, .h-promises li + li { padding-block: 18px; padding-inline: 0 12px; border-inline-start: 0; }
  .h-promises li:nth-child(even) { padding-inline-start: 14px; border-inline-start: 1px solid var(--line); }
  .h-promises li:nth-child(n + 3) { border-top: 1px solid var(--line); }
  .h-promises b { font-size: 14.5px; }
  .h-promises span { font-size: 13px; }

  .home .sect { padding: 56px 0; }
  .svc { grid-template-columns: 1fr 1fr; gap: 22px 12px; margin-top: 24px; }
  .svc img { border-radius: var(--r-md); }
  .svc-t { margin-top: 10px; font-size: 15.5px; }
  .svc-p { font-size: 13.5px; }

  .h-steps { grid-template-columns: 1fr; gap: 26px; margin: 28px 0 30px; }
  .h-steps li { display: grid; grid-template-columns: 44px 1fr; column-gap: 12px; padding-top: 18px; }
  .h-steps .n { font-size: 30px; grid-row: span 2; }
  .h-steps h3 { margin-top: 2px; font-size: 16.5px; }
  .h-steps p { margin-top: 6px; font-size: 14.5px; }

  .h-homes { grid-template-columns: 1fr; gap: 34px; margin-top: 24px; }
  .h-homes img { border-radius: var(--r-md); }
  .h-homes h3 { margin-top: 14px; font-size: 17.5px; }

  .home .why-grid, .home .why-grid.three { grid-template-columns: 1fr; }
  .service .h-photo { aspect-ratio: 2 / 1; } /* their leads run longer than the home page's */
  .home .why { padding: 20px 0 22px; }

  .h-close { padding: 52px 0 56px; }
  .h-close-in { grid-template-columns: 1fr; }
  .h-close figure { display: none; }
}
@media (max-width: 560px) {
  .h-cta .btn { width: 100%; }

  /* Three cards do not split into two columns; on a phone they are rows. */
  .svc.three { grid-template-columns: 1fr; gap: 0; }
  .svc.three a { display: grid; grid-template-columns: 76px 1fr; column-gap: 14px; padding: 12px 0; border-top: 1px solid var(--warm-line); }
  .svc.three li:last-child a { border-bottom: 1px solid var(--warm-line); }
  .svc.three img { grid-row: span 2; aspect-ratio: 1; border-radius: var(--r-sm); }
  .svc.three .svc-t { margin-top: 0; align-self: end; }
  .svc.three .svc-p { align-self: start; }
  .h-cta { justify-content: center; gap: 4px; }
  .h-close .h-cta { gap: 10px; }

  .h-dock {
    display: flex; gap: 10px; align-items: center;
    position: fixed; z-index: 30; left: 0; right: 0; bottom: 0;
    padding: 10px 16px calc(10px + env(safe-area-inset-bottom, 0px));
    background: rgba(255, 255, 255, .92); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
    border-top: 1px solid var(--line);
    transform: translateY(100%); visibility: hidden;
    transition: transform .4s var(--ease-out), visibility 0s .4s;
  }
  .h-dock.on { transform: none; visibility: visible; transition: transform .4s var(--ease-out); }
  .h-dock .btn { flex: 1; }
  .h-dock-wa {
    display: inline-flex; align-items: center; justify-content: center; width: 46px; height: 46px; flex: none;
    border: 1.5px solid var(--line); border-radius: 14px; background: #fff;
  }
  .h-dock-wa .ico { width: 22px; height: 22px; color: #25d366; }
  #how .wrap > .btn { display: none; } /* the dock is on screen right there */
}
@media (prefers-reduced-motion: reduce) {
  .h-photo img { animation: none; }
  .svc img, .h-dock, .h-dock.on { transition: none; }
}

/* ---------- Opening (assets/intro.js) ----------
   The page arrives under grime and the extraction tool cleans it off while a
   counter runs to 100%. Shown once per visit, never with reduced motion. */
#intro { display: none; }
html.intro #intro {
  display: block; position: fixed; inset: 0; z-index: 100; cursor: pointer;
  transition: opacity .4s ease; -webkit-user-select: none; user-select: none;
}
html.intro body { overflow: hidden; }
#intro canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
#intro .intro-wand {
  position: absolute; left: 0; top: 0; height: auto; pointer-events: none; will-change: transform;
  filter: drop-shadow(0 12px 18px rgba(23, 25, 28, .28));
}
.intro-ring {
  position: absolute; left: 50%; top: 50%; width: 112px; height: 112px; margin: -56px 0 0 -56px;
  display: grid; place-items: center; align-content: center; border-radius: 50%;
  background: rgba(23, 25, 28, .9); color: #fff; box-shadow: 0 14px 34px rgba(23, 25, 28, .32);
  transition: transform .4s var(--ease-out, ease);
}
.intro-ring svg { position: absolute; inset: 7px; width: calc(100% - 14px); height: calc(100% - 14px); transform: rotate(-90deg); }
.intro-ring circle { fill: none; stroke-width: 3; }
.intro-track { stroke: rgba(255, 255, 255, .14); }
.intro-arc { stroke: var(--blue); stroke-linecap: round; stroke-dasharray: 100; stroke-dashoffset: 100; }
.intro-pct { position: relative; font-family: var(--font-display); font-weight: 600; font-size: 26px; line-height: 1; letter-spacing: -.02em; }
.intro-ring small { position: relative; margin-top: 5px; font-size: 9.5px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: rgba(255, 255, 255, .72); }
#intro.out { opacity: 0; }
#intro.out .intro-ring { transform: scale(.88); }
@media (prefers-reduced-motion: reduce) { #intro { display: none !important; } }

/* ---------- Phone: the site as an app ----------
   On a phone the page reads like an iOS app: a grey grouped ground, white
   rounded groups with hairline rows, a glass bar on top, the photograph as an
   inset card, the services on a shelf that scrolls sideways, and a floating
   glass dock at the bottom. */
@media (max-width: 560px) {
  .home { --ios-bg: #f2f4f7; background: var(--ios-bg); }
  .home .topbar {
    background: rgba(242, 244, 247, .72); border-bottom-color: rgba(23, 25, 28, .06);
    -webkit-backdrop-filter: blur(20px) saturate(180%); backdrop-filter: blur(20px) saturate(180%);
  }
  .home .sect, .home .sect.alt, .home #prices, .home #homes, .home #areas, .h-hero, .h-shelf, .h-promises { background: transparent; }
  .home .sect { padding: 30px 0 4px; }
  .home .sect h2, .h-shelf h2 { font-size: 22px; letter-spacing: -0.02em; padding-inline: 4px; }
  .home .sect-sub, .home #prices .sect-sub, .home #areas .sect-sub { color: var(--muted-warm); padding-inline: 4px; font-size: 14.5px; }

  /* The photograph is a card inside the margins, not a band. */
  .h-photo { margin: 8px 16px 0; border-radius: 24px; box-shadow: 0 10px 28px rgba(23, 25, 28, .12); }
  .home:not(.service) .h-photo { aspect-ratio: 16 / 10; }
  .home:not(.service) .h-photo img { object-position: 50% 66%; }
  .h-copy { padding: 18px 20px 0; }
  .h-copy h1 { font-size: 27px; line-height: 1.12; }
  .h-copy .lead { font-size: 15.5px; }
  .h-cta .btn { height: 54px; border-radius: 16px; }

  /* The shelf scrolls sideways, App Store fashion. */
  .h-shelf { padding: 26px 0 6px; }
  .shelf {
    display: flex; gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
    margin: 12px -16px 0; padding: 2px 16px 10px; scroll-padding-inline: 16px;
  }
  .shelf::-webkit-scrollbar { display: none; }
  .shelf li { flex: 0 0 128px; scroll-snap-align: start; }
  .shelf a { border-color: transparent; }
  .shelf-more { padding-inline: 4px; }

  /* Groups: white, rounded, rows divided by inset hairlines. */
  .h-promises { margin: 16px 0 0; border: 0; }
  .h-promises ul {
    display: block; margin: 0 16px; padding: 2px 16px; background: #fff; border-radius: 22px; box-shadow: var(--shadow-sm);
  }
  .h-promises li, .h-promises li + li, .h-promises li:nth-child(even), .h-promises li:nth-child(n + 3) {
    padding: 13px 0; border: 0;
  }
  .h-promises li + li { border-top: 1px solid var(--line-2); }
  .h-promises li .ico { width: 30px; height: 30px; padding: 6px; border-radius: 9px; background: var(--blue); color: #fff; }
  .h-promises b { font-size: 15px; }
  .h-promises span { margin-top: 2px; font-size: 13.5px; }

  .h-steps { display: block; margin-top: 14px; padding: 4px 16px; background: #fff; border-radius: 22px; box-shadow: var(--shadow-sm); }
  .h-steps li { padding: 14px 0; border-top: 1px solid var(--line-2); }
  .h-steps li:first-child { border-top: 0; }

  .home .why-grid { margin-top: 14px; padding: 2px 16px; background: #fff; border-radius: 22px; box-shadow: var(--shadow-sm); }
  .home .why, .home .sect.alt .why { padding: 15px 0; border-top: 1px solid var(--line-2); }
  .home .why:first-child { border-top: 0; }
  .home .why p, .home .sect.alt .why p { color: var(--muted); }

  .h-homes figure { background: #fff; border-radius: 22px; overflow: hidden; box-shadow: var(--shadow-sm); }
  .h-homes img { border-radius: 0; }
  .h-homes figcaption { padding: 2px 16px 16px; }
  .h-homes p { color: var(--muted); }

  .home .areas { padding: 14px; background: #fff; border-radius: 22px; box-shadow: var(--shadow-sm); }
  .home .areas li { background: var(--ios-bg); border-color: transparent; }

  .home .faq { margin-top: 14px; padding: 0 16px; background: #fff; border-radius: 22px; box-shadow: var(--shadow-sm); }
  .home .faq details:last-child { border-bottom: 0; }
  .home .faq summary { font-size: 15px; padding: 15px 0; }

  .home #prices .price-card { border-radius: 22px; }
  .home #prices .quote-box { border-radius: 22px; }
  .svc.three { padding: 0 14px; background: #fff; border-radius: 22px; box-shadow: var(--shadow-sm); }
  .svc.three a, .svc.three li:last-child a { border-color: var(--line-2); }
  .svc.three li:first-child a { border-top: 0; }
  .svc.three li:last-child a { border-bottom: 0; }

  .h-close { margin: 30px 16px 0; padding: 34px 0 36px; border-radius: 26px; }
  .h-close .wrap { padding: 0 20px; }
  .home .foot { margin-top: 30px; background: transparent; border-top-color: rgba(23, 25, 28, .08); }

  /* The dock floats, glass, like the system's own bars. */
  .h-dock {
    left: 12px; right: 12px; bottom: calc(10px + env(safe-area-inset-bottom, 0px));
    padding: 8px; border-radius: 26px; border: 1px solid rgba(255, 255, 255, .8);
    background: rgba(255, 255, 255, .62);
    -webkit-backdrop-filter: blur(24px) saturate(190%); backdrop-filter: blur(24px) saturate(190%);
    box-shadow: 0 12px 32px rgba(23, 25, 28, .16), inset 0 1px 0 rgba(255, 255, 255, .9);
    transform: translateY(140%);
  }
  .h-dock .btn { height: 48px; border-radius: 18px; }
  .h-dock-wa { border-radius: 18px; border-color: rgba(23, 25, 28, .08); }
}

/* ---------- Arabic (/ar) ----------
   Arabic letters do not take the tight tracking the Latin headings use, and
   they need more room between lines than Poppins. Digits stay Latin, as on
   the booking pages; a phone number keeps its own direction. */
:root:lang(ar) {
  --font-display: "Noto Sans Arabic", "Poppins", system-ui, sans-serif;
  --font-body: "Noto Sans Arabic", "Inter", system-ui, sans-serif;
}
.home:lang(ar) :is(h1, h2, h3, b, .shelf b, .h-price b, .svc-t, .intro-pct) { letter-spacing: 0; }
.home:lang(ar) .h-copy h1 { line-height: 1.3; }
.home:lang(ar) .sect h2, .home:lang(ar) .h-close h2, .home:lang(ar) .sect h2.h-from { line-height: 1.35; }
.home:lang(ar) .intro-ring small { letter-spacing: 0; text-transform: none; font-size: 11px; }
[dir="rtl"] .ltr { direction: ltr; unicode-bidi: isolate; }
.home:lang(ar) .price-card li b::after { content: " درهم"; }
