/* «Индивидуальный заказ»: страница /individualnyy-zakaz/ и баннер на главной.
 *
 * Рукописный файл (13.10.2026). Подключается ТОЛЬКО на этих двух страницах,
 * через блок head_extra. Здесь то, чего нет в образцах макета: сетки плиток,
 * форма, область выбора файла, баннер. Кнопки и карточки стоят в разметке
 * инлайном, буква в букву с образцов: их узнаёт слой look.css.
 *
 * АДАПТИВ. Страница рисует тело дважды: `.dc-desktop` виден от 768.02px,
 * `.dc-mobile` до 768px (storefront.css). Поэтому «телефон» здесь это
 * селектор `.dc-mobile …`, а «планшет» это узкий `.dc-desktop` по медиазапросу.
 * Все колонки сеток `minmax(0, 1fr)`: длинное слово не распирает страницу.
 */

/* ── Заголовки и вводный текст ───────────────────────────────────────────── */

.co-h1 {
  margin: 0;
  font-family: 'Playfair Display', Georgia, serif;
  font-size: clamp(34px, 3.9vw, 54px);
  font-weight: 900;
  letter-spacing: -.025em;
  line-height: 1.04;
  color: #2E1D25;
}
.co-h2 {
  margin: 0 0 20px;
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 34px;
  font-weight: 900;
  letter-spacing: -.02em;
  line-height: 1.1;
  color: #2E1D25;
}
.co-lead {
  margin: 18px 0 0;
  font-size: 18px;
  line-height: 1.55;
  color: #2E1D25;
}
.co-sec { margin-top: 44px; }

.dc-mobile .co-h1 { font-size: 30px; }
.dc-mobile .co-h2 { font-size: 23px; margin-bottom: 14px; }
.dc-mobile .co-lead { font-size: 15px; margin-top: 12px; }
.dc-mobile .co-sec { margin-top: 28px; }

/* ── 1. Первый экран ─────────────────────────────────────────────────────── */

.co-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  align-items: stretch;
  overflow: hidden;
}
.co-hero__text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  padding: 44px 40px;
}
.co-hero__buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 30px;
}
.co-hero__pic { margin: 0; min-width: 0; min-height: 100%; }
.co-hero__pic img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 320px;
  object-fit: cover;
}
@media (min-width: 768.02px) and (max-width: 1023px) {
  .co-hero__text { padding: 30px 26px; }
}
.dc-mobile .co-hero { grid-template-columns: minmax(0, 1fr); }
.dc-mobile .co-hero__text { padding: 24px 20px 20px; }
.dc-mobile .co-hero__buttons { flex-direction: column; gap: 10px; margin-top: 20px; }
.dc-mobile .co-hero__pic img { min-height: 0; height: auto; aspect-ratio: 3 / 2; }

/* ── 2. Плитки «Что можем создать» ───────────────────────────────────────── */
/* Шесть в ряд от 1280, три на планшете, две на телефоне. */

.co-tiles {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
@media (min-width: 1280px) {
  .co-tiles { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 16px; }
}
.dc-mobile .co-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }

.co-tile {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.co-tile__pic {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: 18px;
}
.co-tile__title {
  display: block;
  margin: 14px 4px 6px;
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.2;
  overflow-wrap: break-word; hyphens: auto; -webkit-hyphens: auto;
}
.co-tile__text {
  margin: 0 4px 12px;
  font-size: 14px;
  line-height: 1.45;
  color: #8A7079;
}
.co-tile__more {
  margin: auto 4px 6px;
  font-family: 'PT Mono', monospace;
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #C9436E;
  text-decoration: none;
}
.co-tile__more:hover { text-decoration: underline; }
.co-tile__more:focus-visible { outline: 3px solid #EE7598; outline-offset: 3px; border-radius: 6px; }
.dc-mobile .co-tile__title { font-size: 15px; margin-top: 10px; }
.dc-mobile .co-tile__text { font-size: 13px; }

/* ── 3. «Для кого мы работаем» ───────────────────────────────────────────── */

.co-who {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 26px 20px;
}
@media (min-width: 1280px) {
  .co-who { grid-template-columns: repeat(6, minmax(0, 1fr)); }
}
.dc-mobile .co-who { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 12px; }

.co-who__item { min-width: 0; }
.co-who__pic { display: block; width: 88px; height: 88px; object-fit: contain; }
.co-who__title {
  display: block;
  margin: 10px 0 6px;
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.2;
  overflow-wrap: break-word; hyphens: auto; -webkit-hyphens: auto;
}
.co-who__text { margin: 0; font-size: 14px; line-height: 1.45; color: #8A7079; }
.dc-mobile .co-who__pic { width: 64px; height: 64px; }
.dc-mobile .co-who__title { font-size: 15px; }
.dc-mobile .co-who__text { font-size: 13px; }

/* ── 4. Шаги ─────────────────────────────────────────────────────────────── */

.co-steps {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
}
@media (min-width: 1100px) {
  .co-steps { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
.dc-mobile .co-steps { grid-template-columns: minmax(0, 1fr); gap: 10px; }

/* ── 5. Форма заявки ─────────────────────────────────────────────────────── */

.co-request {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 26px;
  /* Якорь не должен прятаться под закреплённой строкой шапки. */
  scroll-margin-top: 96px;
}
@media (min-width: 1100px) {
  .co-request { grid-template-columns: minmax(0, .8fr) minmax(0, 1.6fr); gap: 40px; }
}
.co-request .co-h2 { margin-bottom: 0; }
.co-request__intro { min-width: 0; }
.co-sec[id] { scroll-margin-top: 96px; }
.dc-mobile .co-request { gap: 18px; scroll-margin-top: 16px; }
.dc-mobile .co-sec[id] { scroll-margin-top: 16px; }

.co-form { min-width: 0; }
.co-form__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px 20px;
  margin-bottom: 18px;
}
.dc-mobile .co-form__grid { grid-template-columns: minmax(0, 1fr); gap: 14px; }

.co-field { display: block; min-width: 0; }
.co-field__label {
  display: block;
  margin-bottom: 7px;
  font-size: 14px;
  font-weight: 700;
  color: #2E1D25;
}
.co-field input[type="text"],
.co-field select {
  display: block;
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  border: 0;
  border-radius: 18px;
  background-color: #FFEBF2;
  box-shadow: inset 4px 4px 10px rgba(206, 140, 166, .30),
              inset -4px -4px 10px rgba(255, 255, 255, .95);
  padding: 14px 18px;
  font: inherit;
  font-size: 16px;
  line-height: 1.3;
  color: #2E1D25;
}
.co-field select {
  -webkit-appearance: none;
  appearance: none;
  padding-right: 44px;
  /* Стрелка списка своя: системная на айфоне и на ПК выглядит по-разному. */
  background-image: linear-gradient(45deg, transparent 50%, #C9436E 50%),
                    linear-gradient(135deg, #C9436E 50%, transparent 50%);
  background-position: calc(100% - 23px) 50%, calc(100% - 17px) 50%;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  cursor: pointer;
}
.co-field input::placeholder { color: #8A7079; opacity: 1; }
.co-field input[type="text"]:focus-visible,
.co-field select:focus-visible {
  outline: 3px solid #EE7598;
  outline-offset: 2px;
}
.co-field [aria-invalid="true"] { box-shadow: 0 0 0 2px #C9436E; }

.co-err {
  display: block;
  margin-top: 6px;
  font-size: 13px;
  line-height: 1.4;
  color: #C9436E;
}
.co-err[hidden] { display: none; }
.co-hint { display: block; margin-top: 6px; font-size: 13px; line-height: 1.4; color: #8A7079; }
.co-alert {
  margin: 0 0 16px;
  padding: 14px 18px;
  border-radius: 18px;
  background: #FFD6E4;
  font-size: 15px;
  line-height: 1.45;
  color: #2E1D25;
}
.co-ok {
  align-self: center;
  margin: 0;
  padding: 22px 24px;
  border-radius: 22px;
  background: #FFD6E4;
  font-size: 17px;
  line-height: 1.5;
  color: #2E1D25;
}

/* Ловушка для роботов: убрана с экрана, но не через display:none - роботы,
   которые пропускают скрытые поля, проходили бы её насквозь. */
.co-hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* ── Область выбора файла (правило Павла: системной кнопки нет) ──────────── */
/* Образец: reviews-media.css (.rmd-drop) и reviews.css (.rv__file-native). */

.co-file { position: relative; }
/* ⚠ НЕ `display:none` и НЕ `visibility:hidden`: они выкидывают поле из порядка
   обхода, и до выбора файла не добраться ни клавиатурой, ни скринридером.
   Поле остаётся в потоке, но прозрачное и в 0.1 пикселя. */
.co-file__native {
  position: absolute;
  opacity: 0;
  width: .1px;
  height: .1px;
  overflow: hidden;
  z-index: -1;
}
.co-drop {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 56px;
  box-sizing: border-box;
  padding: 8px 14px;
  border: 2px dashed rgba(238, 117, 152, .55);
  border-radius: 18px;
  background: rgba(238, 117, 152, .06);
  color: #2E1D25;
  cursor: pointer;
  transition: background .14s, border-color .14s;
  user-select: none;
}
.co-drop:hover,
.co-drop--over {
  background: rgba(238, 117, 152, .14);
  border-color: #EE7598;
}
/* Фокус стоит на спрятанном поле, поэтому кольцо рисуется на области. */
.co-file:focus-within .co-drop {
  outline: 3px solid #EE7598;
  outline-offset: 3px;
}
.co-drop__plus {
  display: flex;
  flex: 0 0 36px;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 12px;
  background: #EE7598;
  color: #fff;
  font-size: 22px;
  font-weight: 800;
  line-height: 1;
}
.co-drop__title {
  min-width: 0;
  font-size: 15px;
  font-weight: 700;
  overflow-wrap: anywhere;
}
.co-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  max-width: 100%;
  box-sizing: border-box;
  margin-top: 8px;
  padding: 6px 6px 6px 14px;
  border-radius: 999px;
  background: #FFD6E4;
  font-size: 14px;
  color: #2E1D25;
}
.co-chip[hidden] { display: none; }
.co-chip__name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.co-chip__x {
  flex: 0 0 28px;
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 50%;
  background: #FFF8FB;
  color: #C9436E;
  font-size: 13px;
  line-height: 1;
  cursor: pointer;
}
.co-chip__x:focus-visible { outline: 3px solid #EE7598; outline-offset: 2px; }

/* ── Согласие ────────────────────────────────────────────────────────────── */

.co-check {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 18px;
  font-size: 15px;
  line-height: 1.5;
  cursor: pointer;
}
.co-check a { color: #C9436E; }
/* Галочка та же, что у согласия в регистрации (account.css, .acc-check). */
.co-check input {
  -webkit-appearance: none;
  appearance: none;
  flex: 0 0 22px;
  width: 22px;
  height: 22px;
  margin: 2px 0 0;
  border: 0;
  border-radius: 8px;
  background: #FFEBF2;
  box-shadow: inset 3px 3px 7px rgba(206, 140, 166, .30),
              inset -3px -3px 7px rgba(255, 255, 255, .95);
  display: grid;
  place-items: center;
  cursor: pointer;
}
.co-check input::after {
  content: "✓";
  font-size: 12px;
  line-height: 1;
  color: transparent;
}
.co-check input:checked { background: #EE7598; box-shadow: 3px 3px 8px rgba(238, 117, 152, .45); }
.co-check input:checked::after { color: #fff; }
.co-check input:focus-visible { outline: 3px solid #EE7598; outline-offset: 2px; }
.co-check input[aria-invalid="true"] { box-shadow: 0 0 0 2px #C9436E; }

/* ── Баннер на главной (partials/custom_order_banner.html) ───────────────── */
/* banner.jpg 1600×533: слева карточка «Ваш бренд» с пионами, справа свободное
   розовое поле. На ПК текст стоит поверх правого поля, на телефоне картинка
   сверху, текст под ней: в полосу 3:1 шириной с телефон текст не помещается. */

.co-banner {
  position: relative;
  display: block;
  margin: 30px 0 0;
  border-radius: 28px;
  overflow: hidden;
  background: #FFE3EC;
  box-shadow: 8px 8px 20px rgba(206, 140, 166, .28), -8px -8px 20px rgba(255, 255, 255, .9);
}
.co-banner__pic {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: left center;
}
.co-banner__body {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px 28px;
  min-height: 190px;
  box-sizing: border-box;
  margin-left: 40%;
  padding: 28px 36px 28px 0;
}
.co-banner__text { flex: 1 1 320px; min-width: 0; }
.co-banner__badge {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 999px;
  background: #C9436E;
  color: #fff;
  font-family: 'PT Mono', monospace;
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.co-banner__title {
  display: block;
  margin: 12px 0 8px;
  font-family: 'Playfair Display', Georgia, serif;
  font-size: clamp(22px, 2.4vw, 32px);
  font-weight: 900;
  letter-spacing: -.02em;
  line-height: 1.1;
  color: #2E1D25;
}
.co-banner__lead { margin: 0; font-size: 15px; line-height: 1.5; color: #2E1D25; }
.co-banner__btn { flex: 0 0 auto; }

@media (min-width: 768.02px) and (max-width: 1023px) {
  /* Планшет: правое поле картинки узкое, под текст кладём светлую подложку. */
  .co-banner__body {
    margin-left: 34%;
    padding: 20px 22px;
    background: rgba(255, 235, 242, .88);
  }
}
@media (max-width: 768px) {
  .co-banner { margin-top: 16px; border-radius: 24px; }
  .co-banner__pic {
    position: static;
    height: auto;
    aspect-ratio: 16 / 7;
  }
  .co-banner__body {
    display: block;
    min-height: 0;
    margin-left: 0;
    padding: 16px 18px 20px;
  }
  .co-banner__title { font-size: 22px; }
  .co-banner__lead { font-size: 14px; }
  .co-banner__btn {
    width: 100%;
    box-sizing: border-box;
    margin-top: 14px;
    padding: 17px 24px !important;
  }
}
