/* Palette matched to iOS/Android SerelizTheme */
:root {
  --black: #000000;
  --warm-black: #0f0a08;
  --deep-ink: #1f140f;
  --peach: #fcdcb8;
  --gold: #fac86c;
  --apricot: #faba7c;
  --coral: #f98e60;
  --coral-deep: #f76b4a;
  --mark-mid: #fe9c67;
  --cream: #fff7f0;

  --brand: var(--deep-ink);
  --muted: rgba(31, 20, 15, 0.55);
  --accent: var(--coral-deep);
  --on-button: var(--cream);
  --button-fill: var(--deep-ink);
  --hairline: rgba(31, 20, 15, 0.18);

  --font-display: "Fraunces", "Iowan Old Style", "Palatino Linotype", Palatino, serif;
  --font-body: "Source Serif 4", "Iowan Old Style", Georgia, serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--brand);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  background: linear-gradient(
    145deg,
    var(--peach) 0%,
    var(--gold) 48%,
    var(--coral) 100%
  );
  overflow-x: hidden;
}

/* Film grain — subtle, like print on warm light */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 3;
  opacity: 0.22;
  mix-blend-mode: soft-light;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 220 220' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.55'/%3E%3C/svg%3E");
}

a {
  color: var(--accent);
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--brand);
}

.page {
  position: relative;
  z-index: 1;
  min-height: 100vh;
}

/* Soft ambient orb — mirrors Splash AmbientGlow */
.ambient {
  position: absolute;
  width: min(140vw, 720px);
  height: min(140vw, 720px);
  left: 50%;
  top: 38%;
  border-radius: 50%;
  background: radial-gradient(
    circle at center,
    rgba(255, 247, 240, 0.62) 0%,
    rgba(250, 200, 108, 0.28) 38%,
    transparent 70%
  );
  filter: blur(8px);
  pointer-events: none;
  transform: translate(-50%, -50%);
  animation: ambient-in 1.2s ease both, ambient-drift 14s ease-in-out 1.2s infinite alternate;
}

.shell {
  position: relative;
  width: min(920px, calc(100% - 2.75rem));
  margin: 0 auto;
  padding: 1.35rem 0 0;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  position: relative;
  z-index: 2;
}

.brand-lockup {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
  color: var(--brand);
}

.brand-lockup img {
  width: 1.65rem;
  height: 1.65rem;
  border-radius: 0.4rem;
  object-fit: cover;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.35);
}

.brand-lockup span {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 500;
  letter-spacing: 0.08em;
}

.lang {
  display: inline-flex;
  align-items: baseline;
  gap: 0.55rem;
  font-size: 0.86rem;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.lang button {
  appearance: none;
  border: 0;
  background: none;
  padding: 0;
  font: inherit;
  letter-spacing: inherit;
  color: inherit;
  cursor: pointer;
  border-bottom: 1px solid transparent;
}

.lang button[aria-pressed="true"] {
  color: var(--brand);
  border-bottom-color: var(--accent);
}

.lang .sep {
  opacity: 0.35;
}

/* ——— Home hero: one composition ——— */
.home {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.hero {
  position: relative;
  flex: 1;
  display: grid;
  align-content: center;
  padding: clamp(3.5rem, 12vh, 7rem) 0 clamp(3rem, 8vh, 5rem);
  min-height: calc(100vh - 4.5rem);
}

.hero-inner {
  position: relative;
  z-index: 2;
  max-width: 38rem;
}

.hero-mark {
  width: 4.25rem;
  height: 4.25rem;
  border-radius: 1.05rem;
  object-fit: cover;
  margin-bottom: 1.6rem;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.28),
    0 18px 40px rgba(80, 28, 8, 0.18);
  animation: rise 0.95s ease both;
}

.hero h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(4.2rem, 14vw, 7.2rem);
  font-weight: 450;
  letter-spacing: 0.015em;
  line-height: 0.92;
  color: var(--brand);
  animation: rise 1s ease 0.08s both;
}

.accent-line {
  width: 3rem;
  height: 1.5px;
  margin: 1.35rem 0 1.4rem;
  border-radius: 1px;
  background: var(--accent);
  transform-origin: left center;
  animation: draw 0.85s ease 0.28s both;
}

.lede {
  margin: 0;
  max-width: 26rem;
  color: var(--muted);
  font-size: clamp(1.05rem, 2.4vw, 1.22rem);
  line-height: 1.55;
  animation: rise 0.95s ease 0.35s both;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.5rem;
  margin-top: 2.1rem;
  animation: rise 0.95s ease 0.48s both;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.85rem;
  padding: 0.7rem 1.35rem;
  border-radius: 0.55rem;
  background: var(--button-fill);
  color: var(--on-button);
  font-family: var(--font-body);
  font-size: 0.98rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  text-decoration: none;
  transition: transform 0.2s ease, background 0.2s ease;
}

.btn:hover {
  color: var(--on-button);
  background: #2a1c15;
  transform: translateY(-1px);
}

.link-quiet {
  color: var(--brand);
  text-decoration: none;
  border-bottom: 1px solid rgba(247, 107, 74, 0.55);
  font-size: 0.98rem;
}

.link-quiet:hover {
  border-bottom-color: var(--brand);
}

/* Below-fold: one job */
.band {
  position: relative;
  z-index: 2;
  padding: 0 0 4.5rem;
}

.band-rule {
  width: 100%;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--hairline) 18%,
    var(--hairline) 82%,
    transparent
  );
  margin-bottom: 2.4rem;
}

.band h2 {
  margin: 0 0 0.75rem;
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 4vw, 2.1rem);
  font-weight: 500;
  letter-spacing: 0.01em;
}

.band p {
  margin: 0;
  max-width: 32rem;
  color: var(--muted);
  font-size: 1.05rem;
}

.band-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.6rem;
  margin-top: 1.5rem;
}

.band-links a {
  color: var(--brand);
  text-decoration: none;
  border-bottom: 1px solid rgba(247, 107, 74, 0.45);
  font-size: 0.98rem;
}

.band-links a:hover {
  border-bottom-color: var(--brand);
}

/* ——— Legal pages ——— */
body.legal {
  background: linear-gradient(
    180deg,
    #fce6c7 0%,
    var(--apricot) 42%,
    var(--coral) 100%
  );
}

body.legal .ambient {
  top: 18%;
  opacity: 0.75;
  animation: ambient-in 1s ease both;
}

.legal-main {
  position: relative;
  z-index: 2;
  padding: 2.5rem 0 1rem;
}

.page-title {
  margin: 0 0 0.4rem;
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 7vw, 3.4rem);
  font-weight: 450;
  letter-spacing: 0.01em;
  line-height: 1.02;
  animation: rise 0.8s ease both;
}

.meta {
  margin: 0 0 1.85rem;
  color: var(--muted);
  font-size: 0.95rem;
  animation: rise 0.8s ease 0.08s both;
}

.prose {
  max-width: 40rem;
  padding: 0 0 0.5rem;
  animation: rise 0.85s ease 0.14s both;
}

.prose h2 {
  margin: 2.1rem 0 0.55rem;
  font-family: var(--font-display);
  font-size: 1.28rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  color: var(--brand);
}

.prose h2:first-child {
  margin-top: 0;
}

.prose p,
.prose ul {
  margin: 0 0 0.85rem;
  color: rgba(31, 20, 15, 0.82);
}

.prose ul {
  padding-left: 1.15rem;
}

.prose li + li {
  margin-top: 0.3rem;
}

.footer {
  position: relative;
  z-index: 2;
  margin-top: 2.75rem;
  padding-bottom: 3rem;
  color: var(--muted);
  font-size: 0.92rem;
}

.footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem 1.35rem;
  margin-bottom: 0.85rem;
}

.footer a {
  color: var(--brand);
  text-decoration: none;
  border-bottom: 1px solid transparent;
}

.footer a:hover {
  border-bottom-color: var(--accent);
}

[data-lang-block] {
  display: none !important;
}

html[lang="ru"] [data-lang-block="ru"],
html[lang="en"] [data-lang-block="en"] {
  display: block !important;
}

html[lang="ru"] span[data-lang-block="ru"],
html[lang="en"] span[data-lang-block="en"] {
  display: inline !important;
}

html[lang="ru"] nav[data-lang-block="ru"],
html[lang="en"] nav[data-lang-block="en"] {
  display: flex !important;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes draw {
  from {
    opacity: 0;
    transform: scaleX(0);
  }
  to {
    opacity: 1;
    transform: scaleX(1);
  }
}

@keyframes ambient-in {
  from {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.88);
  }
  to {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
}

@keyframes ambient-drift {
  from {
    transform: translate(-50%, -50%) scale(1);
  }
  to {
    transform: translate(-46%, -54%) scale(1.05);
  }
}

@media (max-width: 640px) {
  .hero-mark {
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 0.9rem;
  }

  .cta-row {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
