/*
 * tury-vyhodnogo-dnya.css — оформление страницы «Туры выходного дня из Ярославля» (/tury-vyhodnogo-dnya).
 *
 * Слой дополняет редакционную систему styles.css (.home-*) и каркас
 * route.css (.rt-*): здесь только то, чего нет в общих файлах, под
 * префиксом tv-. Фирменный элемент страницы — «билет выходного дня»,
 * два бумажных талона «Суббота → Воскресенье» в hero. Токены, шрифты
 * и палитра — из styles.css, новых цветов не вводим.
 */

/* --- Hero: билет выходного дня «суббота → воскресенье» -------------------- */
.tv-weekend { position: relative; display: grid; gap: .95rem; max-width: 420px; margin-left: auto; padding-right: 1.4rem; }
.tv-ticket { position: relative; padding: 1.15rem 1.3rem 1.2rem; background: var(--paper); color: var(--ink); box-shadow: 0 18px 40px rgba(0, 0, 0, .24); }
.tv-ticket::before { content: ""; position: absolute; inset: .45rem; border: 1px dashed rgba(8, 47, 60, .22); pointer-events: none; }
.tv-ticket:first-child { transform: rotate(.8deg); }
.tv-ticket--day2 { transform: rotate(-1.2deg); }
.tv-ticket__day { display: inline-flex; align-items: center; gap: .45rem; margin-bottom: .7rem; padding: .24rem .6rem; background: var(--river-950); color: var(--sun); font-size: .58rem; font-weight: 700; letter-spacing: .15em; text-transform: uppercase; }
.tv-ticket--day2 .tv-ticket__day { background: var(--coral); color: var(--white); }
.tv-ticket__list { display: grid; gap: .32rem; margin: 0; padding: 0 .2rem; list-style: none; counter-reset: tv-stop; }
.tv-ticket__list li { position: relative; padding-left: 1.35rem; color: var(--muted); font-size: .72rem; }
.tv-ticket__list li::before { content: "0" counter(tv-stop); counter-increment: tv-stop; position: absolute; left: 0; top: .06rem; color: var(--coral); font-size: .58rem; font-weight: 700; letter-spacing: .08em; }
/* Перфорация отрывного корешка: пунктир + пробитые полукруги по краям. */
.tv-ticket__tear { position: relative; display: block; height: 0; margin: .95rem -1.3rem -.45rem; border-top: 2px dashed rgba(8, 47, 60, .3); }
.tv-ticket__tear::before, .tv-ticket__tear::after { content: ""; position: absolute; top: -9px; width: 16px; height: 18px; background: var(--river-950); }
.tv-ticket__tear::before { left: -9px; border-radius: 0 50% 50% 0; }
.tv-ticket__tear::after { right: -9px; border-radius: 50% 0 0 50%; }
.tv-weekend__note { margin: .25rem 0 0; color: rgba(255, 255, 255, .52); font-size: .64rem; }
.tv-weekend__note i { margin-right: .3rem; color: var(--sun); }
.tv-weekend ~ .home-compass { left: auto; right: 0; top: -4.2rem; }

/* --- Форматы уик-энда ----------------------------------------------------- */
.tv-formats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; border: 1px solid var(--line); background: var(--line); }
.tv-format { position: relative; display: flex; flex-direction: column; padding: 1.8rem 1.6rem; background: var(--paper); transition: background .25s, transform .25s; }
.tv-format:hover, .tv-format:focus-within { background: var(--white); transform: translateY(-3px); }
.tv-format__index { margin-bottom: 1.3rem; color: var(--coral); font-size: .62rem; font-weight: 700; letter-spacing: .15em; }
.tv-format__len { display: block; margin-bottom: .45rem; color: var(--river-800); font-family: var(--display); font-size: clamp(2rem, 3.4vw, 2.9rem); font-weight: 600; letter-spacing: -.045em; line-height: 1; }
.tv-format--sun .tv-format__len { color: var(--coral); }
.tv-format h3 { margin-bottom: .6rem; font-size: 1.25rem; }
.tv-format p { margin-bottom: 0; color: var(--muted); font-size: .74rem; }
.tv-format__links { display: flex; flex-wrap: wrap; gap: .4rem 1.5rem; margin-top: auto; padding-top: 1.15rem; }
.tv-format__links .home-text-link { font-size: .7rem; }

/* --- Плашка «демонстрационные ориентиры» перед таблицей -------------------- */
.tv-table-head { display: flex; margin-bottom: 1.1rem; }
.tv-tag { display: inline-flex; align-items: center; padding: .32rem .75rem; border: 1px dashed rgba(233, 118, 93, .5); color: var(--coral); font-size: .57rem; font-weight: 700; letter-spacing: .15em; text-transform: uppercase; }

/* --- Ссылки в подвалах секций --------------------------------------------- */
.tv-links { display: flex; flex-wrap: wrap; gap: .6rem 1.8rem; }
.tv-links .home-text-link { font-size: .72rem; }

/* --- Вторая таблица: что взять с собой ------------------------------------ */
.tv-pack-head { max-width: 620px; margin-top: 3.4rem; }
.tv-pack-head h3 { margin-bottom: .6rem; font-size: clamp(1.35rem, 2.3vw, 1.95rem); }
.tv-pack-head p { margin-bottom: 1.4rem; color: var(--muted); font-size: .8rem; }
.tv-pack th[scope="row"] { width: 20%; color: var(--river-800); font-size: .8rem; text-align: left; }
.tv-pack td:nth-child(2) { width: 28%; }

/* --- Офферы: часовые рейсы вместо путёвки --------------------------------- */
.tv-vs-note { max-width: 640px; margin: 2.2rem 0 0; color: var(--muted); font-size: .86rem; }
.tv-offers-head { max-width: 620px; margin-top: 3.2rem; }
.tv-offers-head h3 { margin-bottom: .7rem; font-size: clamp(1.3rem, 2.2vw, 1.8rem); }
.tv-offers-head p { margin-bottom: 1.7rem; color: var(--muted); font-size: .8rem; }
/* Компактные карточки офферов по единому спеку: маленькое фото сверху
   (120px) и короткий текстовый блок; размеры — строго по спеку. */
.tv-offers {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 14px;
}
.tv-offer {
  display: flex; flex-direction: column;
  border: 1px solid rgba(10, 30, 51, .12); border-radius: 12px;
  overflow: hidden; background: var(--paper, #fff);
  transition: transform .18s ease, box-shadow .18s ease;
}
.tv-offer:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(10, 30, 51, .08); }
.tv-offer img { width: 100%; height: 120px; object-fit: cover; display: block; }
.tv-offer__body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 6px; }
.tv-offer__badge { font-size: .7rem; letter-spacing: .08em; text-transform: uppercase; opacity: .65; }
.tv-offer__title {
  font-family: var(--display, Georgia, serif);
  font-size: 1rem; line-height: 1.25; margin: 0;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.tv-offer__meta { font-size: .78rem; opacity: .75; display: flex; gap: 10px; flex-wrap: wrap; }
.tv-offer__place { font-size: .78rem; opacity: .75; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tv-offer__price { font-size: .95rem; font-weight: 600; margin-top: auto; }
@media (max-width: 575px) { .tv-offers { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; } .tv-offer img { height: 96px; } }
@media (max-width: 380px) { .tv-offers { grid-template-columns: 1fr; } }
@media (prefers-reduced-motion: reduce) { .tv-offer { transition: none; } .tv-offer:hover { transform: none; } }
.tv-offer:focus-visible, .tv-format__links a:focus-visible { outline: 2px solid var(--coral); outline-offset: 3px; }

/* --- Появление блоков ------------------------------------------------------ */
@keyframes tv-rise {
  from { opacity: 0; transform: translateY(9px); }
  to { opacity: 1; transform: none; }
}

.tv-formats > * { animation: tv-rise .5s cubic-bezier(.2, .7, .2, 1) backwards; }
.tv-formats > *:nth-child(2) { animation-delay: .07s; }
.tv-formats > *:nth-child(3) { animation-delay: .14s; }
.tv-ticket { animation: tv-rise .55s cubic-bezier(.2, .7, .2, 1) backwards; }
.tv-ticket--day2 { animation-delay: .1s; }

@media (prefers-reduced-motion: reduce) {
  .tv-formats > *, .tv-ticket { animation: none; }
  .tv-format { transition: none; }
  .tv-format:hover { transform: none; }
}

@media (max-width: 1024px) {
  .tv-weekend { max-width: 380px; }
  .tv-weekend ~ .home-compass { top: -2.4rem; }
}

@media (max-width: 768px) {
  .tv-weekend { max-width: 460px; margin: 0 auto; padding-right: 0; }
  .tv-weekend ~ .home-compass { right: auto; left: 0; top: -3.4rem; }
  .tv-formats { grid-template-columns: 1fr; }
  .tv-offers-head { margin-top: 2.4rem; }
  .tv-pack-head { margin-top: 2.6rem; }
}

@media (max-width: 390px) {
  .tv-ticket { padding: 1rem 1.05rem 1.1rem; }
  .tv-ticket__tear { margin: .8rem -1.05rem -.4rem; }
  .tv-ticket__tear::before, .tv-ticket__tear::after { width: 13px; height: 15px; }
  .tv-weekend__note { font-size: .6rem; }
  .tv-format { padding: 1.5rem 1.3rem; }
  .tv-pack th[scope="row"], .tv-pack td:nth-child(2) { width: auto; }
  .tv-tag { font-size: .53rem; }
}
