/* ==========================================================================
   /services/brand/ — «Брендовые сайты». Concept: «Центр» — a brand has a
   core, and its own system of images grows around it.
   Hero: symmetric. The star sits on the centre axis; its glow breathes, the
   glints slowly turn, thin orbits ripple out. The artwork is centred on the
   star and fades to black radially, so no edge of the image shows.
   The orbit is the page's motif: the ring markers, the ring around the price.
   Below: everything gathers to the centre axis and grows out of the centre.
   ========================================================================== */

.service-brand {
  --br-y: clamp(150px, 13vw, 190px);                /* star height inside the hero */
  --br-w: clamp(960px, 104vw, 1600px);              /* artwork width */
  --br-orbit: clamp(160px, 15vw, 220px);
  --br-glow: clamp(240px, 23.6vw, 340px);
  --br-ray: clamp(400px, 41.7vw, 600px);
}

/* --- Hero: the star ------------------------------------------------------ */
.br-stage { position: absolute; top: var(--br-y); left: 50%; width: 0; height: 0; }
.br-star {
  position: absolute;
  top: 0;
  left: 0;
  display: block;
  width: var(--br-w);
  mix-blend-mode: screen;
}
.br-star img { width: 100%; height: auto; }
.br-star { transform: translate(-50.15%, -46.11%); }                /* the star point onto the axis */

.br-orbit,
.br-glow {
  position: absolute;
  border-radius: 50%;
}
.br-orbit {
  top: calc(var(--br-orbit) / -2);
  left: calc(var(--br-orbit) / -2);
  width: var(--br-orbit);
  height: var(--br-orbit);
  border: 1px solid rgba(241, 235, 221, .7);
  opacity: 0;
}
.br-glow {
  top: calc(var(--br-glow) / -2);
  left: calc(var(--br-glow) / -2);
  width: var(--br-glow);
  height: var(--br-glow);
  background: radial-gradient(circle, rgba(255, 255, 255, .55) 0%, rgba(220, 224, 230, .18) 18%, rgba(200, 206, 212, .05) 42%, transparent 70%);
}
.br-rays { position: absolute; top: 0; left: 0; width: 0; height: 0; }
.br-rays span { position: absolute; display: block; }
.br-rays span:nth-child(1) { top: 0; left: calc(var(--br-ray) / -2); width: var(--br-ray); height: 1px; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .7) 50%, transparent); }
.br-rays span:nth-child(2) { top: calc(var(--br-ray) / -2); left: 0; width: 1px; height: var(--br-ray); background: linear-gradient(180deg, transparent, rgba(255, 255, 255, .7) 50%, transparent); }
.br-rays span:nth-child(3),
.br-rays span:nth-child(4) { top: 0; left: calc(var(--br-ray) * -.22); width: calc(var(--br-ray) * .44); height: 1px; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .4) 50%, transparent); }
.br-rays span:nth-child(3) { transform: rotate(45deg); }
.br-rays span:nth-child(4) { transform: rotate(-45deg); }

/* static frame (no motion): three still orbits */
.br-o1 { opacity: .35; }
.br-o2 { opacity: .22; transform: scale(1.7); }
.br-o3 { opacity: .12; transform: scale(2.4); }

@media (prefers-reduced-motion: no-preference) {
  .br-glow { animation: br-breathe 7s ease-in-out infinite alternate; }
  .br-rays { animation: br-turn 90s linear infinite; }
  .br-orbit { opacity: 0; animation: br-orbit 12s cubic-bezier(.2, .6, .3, 1) infinite; }
  .br-o2 { animation-delay: 4s; }
  .br-o3 { animation-delay: 8s; }
}
@keyframes br-breathe { from { transform: scale(.82); opacity: .7; } to { transform: scale(1.12); opacity: 1; } }
@keyframes br-turn { to { transform: rotate(360deg); } }
@keyframes br-orbit { 0% { opacity: 0; transform: scale(.3); } 12% { opacity: .5; } 100% { opacity: 0; transform: scale(2.8); } }

/* soften the top edge; darken under the star where the headline sits */
.br-sky::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(14, 15, 15, 1) 0, rgba(14, 15, 15, 0) clamp(90px, 9vw, 150px)),   /* no hard cut under the header */
    linear-gradient(180deg, rgba(14, 15, 15, 0) 34%, rgba(14, 15, 15, .82) 52%, rgba(14, 15, 15, .92) 100%);
}

/* --- Hero: copy on the axis ---------------------------------------------- */
.service-brand .svc-hero {
  justify-content: center;
  align-items: flex-start;
  min-height: 0;
  padding-top: calc(var(--br-y) + clamp(200px, 19vw, 260px));
  text-align: center;
}
.service-brand .svc-hero-copy { display: flex; flex-direction: column; align-items: center; max-width: 880px; margin: 0 auto; }
.service-brand .svc-hero h1 { max-width: none; }
.service-brand .svc-lead { max-width: 34em; }
.service-brand .svc-kicker::before { content: ""; width: 22px; height: 1px; background: currentColor; opacity: .6; }
.service-brand .svc-hero-actions { justify-content: center; }

/* the markers: small glowing stars, echoes of the one in the centre */
.svc-hero-rule.br-mark,
.br-orbits li::before,
.service-brand .svc-intro-text::before {
  width: 22px;
  height: 22px;
  border: 0;
  border-radius: 0;
  background:
    radial-gradient(circle, #fff 0 1.2px, rgba(255, 255, 255, .6) 2px, rgba(228, 232, 236, .16) 4.5px, transparent 9px),
    linear-gradient(90deg, transparent, rgba(255, 255, 255, .8) 50%, transparent) 50% 50% / 100% 1px no-repeat,
    linear-gradient(180deg, transparent, rgba(255, 255, 255, .8) 50%, transparent) 50% 50% / 1px 100% no-repeat;
}
@media (prefers-reduced-motion: no-preference) {
  .svc-hero-rule.br-mark,
  .br-orbits li::before,
  .service-brand .svc-intro-text::before { animation: br-twinkle 5.5s ease-in-out infinite; }
  .service-brand .svc-intro-text::before { animation-delay: -1.4s; }
  .br-orbits li:nth-child(2)::before { animation-delay: -2.2s; }
  .br-orbits li:nth-child(3)::before { animation-delay: -3.6s; }
  .br-orbits li:nth-child(4)::before { animation-delay: -.8s; }
}
@keyframes br-twinkle {
  0%, 100% { opacity: .65; transform: scale(.85); }
  50%      { opacity: 1;   transform: scale(1.1); }
}

/* --- Intro, scope, price: on the axis ------------------------------------ */
.service-brand .svc-intro { grid-template-columns: minmax(0, 1fr); justify-items: center; gap: 28px; text-align: center; }
.service-brand .svc-display { max-width: 14em; }
.service-brand .svc-intro-text { position: relative; max-width: 38em; padding: 34px 0 0; border-left: 0; }
.service-brand .svc-intro-text::before { content: ""; position: absolute; top: 0; left: 50%; margin-left: -11px; }

.service-brand .svc-scope { text-align: center; }
.br-orbits {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(36px, 4vw, 56px) clamp(40px, 6vw, 96px);
  max-width: 1040px;
  margin-right: auto;
  margin-left: auto;
}
.br-orbits li { display: flex; flex-direction: column; align-items: center; }
/* the descriptions: readable on desktop, still airy */
.service-brand .br-orbits p {
  max-width: 28em;
  margin-top: 14px;
  color: rgba(241, 235, 221, .8);
  font-size: clamp(1.0625rem, 1.25vw, 1.1875rem);   /* 17–19px, 18 at 1440 */
  line-height: 1.6;
  text-wrap: pretty;
}
.br-orbits li::before { content: ""; margin-bottom: 14px; }
.br-orbits p { margin-right: auto; margin-left: auto; }

.service-brand .svc-price { text-align: center; }
.service-brand .svc-price-row { display: flex; flex-direction: column; align-items: center; gap: 28px; }
.service-brand .svc-price-slash { display: none; }
.service-brand .svc-price-value { position: relative; padding: .5em 0; }
.service-brand .svc-price-value::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 2.3em;
  height: 2.3em;
  margin: -1.15em 0 0 -1.15em;
  border: 1px solid rgba(241, 235, 221, .16);
  border-radius: 50%;
  pointer-events: none;
}
.service-brand .svc-price-note { display: flex; flex-direction: column; align-items: center; }

/* --- Reveal: grows out of the centre -------------------------------------- */
.svc-motion .service-brand .svc-reveal { transform: scale(.96); transform-origin: 50% 40%; }
.svc-motion .service-brand .svc-reveal.is-visible { transform: none; }
.svc-motion .service-brand .svc-price-value::before { transform: scale(.55); opacity: 0; transition: transform 2.4s cubic-bezier(.16, 1, .3, 1) .3s, opacity 1.6s ease .3s; }
.svc-motion .service-brand .svc-price.is-visible .svc-price-value::before { transform: none; opacity: 1; }
.svc-motion .service-brand .svc-reveal-item { opacity: 0; transform: scale(.94); transition: opacity 1.2s ease, transform 1.4s cubic-bezier(.16, 1, .3, 1); transition-delay: calc(.2s + var(--i, 0) * .16s); }
.svc-motion .service-brand .is-visible .svc-reveal-item { opacity: 1; transform: none; }

/* --- Tablet / mobile ----------------------------------------------------- */
@media (max-width: 960px) {
  .br-orbits { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 680px) {
  .service-brand .br-orbits p { font-size: 1.0625rem; line-height: 1.62; }
  .service-brand { --br-y: 120px; --br-w: 230vw; --br-orbit: 130px; --br-glow: 200px; --br-ray: 320px; }
  .service-brand .svc-hero { padding: calc(var(--br-y) + 170px) 20px 72px; }
  .service-brand .svc-hero-actions { justify-content: center; }
}
