/* Общие стили подстраниц (max, max_predprinimateli, ai2, next).
   У каждой страницы ещё есть свой style.css в её папке. */

@font-face {
  font-family: 'TildaSans';
  src: url('assets/fonts/TildaSans-VF.woff2') format('woff2-variations'),
       url('assets/fonts/TildaSans-VF.woff2') format('woff2');
  font-weight: 250 1000;
  font-style: normal;
  font-display: swap;
}

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

/* clip: никакой элемент не может включить горизонтальную прокрутку страницы */
html { scroll-behavior: smooth; overflow-x: clip; }
body { overflow-x: clip; }

body {
  margin: 0;
  font-family: 'TildaSans', Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

/* height: auto — иначе высота из атрибута height остаётся, а ширина меняется, и картинка растягивается */
img { max-width: 100%; height: auto; display: block; }
h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; }

.wrap {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Градиентная кнопка в стиле MAX */
.btn-max {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 72px;
  padding: 0 44px;
  border-radius: 30px;
  background: linear-gradient(90deg, #00bfff 0%, #5b33ff 55%, #9500ff 100%);
  color: #fff;
  font: 400 22px/1.2 'TildaSans', Arial, sans-serif;
  text-decoration: none;
  transition: transform .2s ease, box-shadow .2s ease, filter .2s ease;
}
.btn-max:hover { transform: translateY(-2px); box-shadow: 0 10px 30px rgba(91, 51, 255, .45); filter: brightness(1.08); }

/* Карточка автора: фото слева, описание справа */
.author {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  max-width: 1160px;
  margin: 0 auto;
}
.author__photo {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 24px;
}
.author__card {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 48px;
  border-radius: 24px;
  background: #fff;
  color: #000;
}
/* Как в Tilda-блоке t545: имя t-heading_xs 28/700, ник t-descr_xs 18, текст t-text_sm 20 */
.author__name { font-size: 28px; font-weight: 700; line-height: 1.23; }
.author__nick { margin-top: 6px; font-size: 18px; line-height: 1.55; color: #9a9a9a; }
.author__line { width: 60px; height: 2px; margin: 28px 0; background: #000; }
.author__text { font-size: 20px; line-height: 1.55; }
.author__text li { position: relative; padding-left: 18px; }
.author__text li + li { margin-top: 6px; }
.author__text li::before { content: '•'; position: absolute; left: 0; }
.author__text p + p { margin-top: 14px; }

@media (max-width: 1200px) {
  .author__name { font-size: 26px; }
  .author__nick { font-size: 16px; }
  .author__text { font-size: 18px; }
}

@media (max-width: 760px) {
  .author { grid-template-columns: 1fr; gap: 16px; }
  .author__name { font-size: 24px; }
  .author__text { font-size: 16px; line-height: 1.45; }
  .author__photo { aspect-ratio: 1 / 1; }
  .author__card { padding: 32px 24px; }
  .btn-max { min-height: 64px; padding: 0 30px; font-size: 19px; }
}

/* Просмотр фото на весь экран (lightbox.js) */
[data-lightbox] img { cursor: zoom-in; }
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 50px 90px;
  background: rgba(0, 0, 0, .9);
}
.lightbox[hidden] { display: none; }
.lightbox__img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 10px; }
.lightbox__close {
  position: absolute;
  top: 16px;
  right: 20px;
  border: 0;
  background: none;
  color: #fff;
  font-size: 44px;
  line-height: 1;
  cursor: pointer;
}
.lightbox__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, .15);
  color: #fff;
  cursor: pointer;
  transition: background-color .2s ease;
}
.lightbox__arrow:hover { background: rgba(255, 255, 255, .3); }
.lightbox__arrow svg {
  width: 45%;
  height: 45%;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.lightbox__arrow_prev { left: 20px; }
.lightbox__arrow_next { right: 20px; }
.lightbox__counter {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 14px;
  text-align: center;
  color: rgba(255, 255, 255, .8);
  font-size: 16px;
}
.lightbox_single .lightbox__arrow,
.lightbox_single .lightbox__counter { display: none; }

@media (max-width: 639px) {
  .lightbox { padding: 50px 10px; }
  .lightbox__arrow { width: 44px; height: 44px; background: rgba(0, 0, 0, .45); }
  .lightbox__arrow_prev { left: 8px; }
  .lightbox__arrow_next { right: 8px; }
}

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