﻿:root {
      --main: #f4e9d0;
    --accent: #8b0000;
    --second-accent: #d4af37;
}
/* ===== ОБЩИЕ ===== */
body {
    margin: 0;
    background: var(--main);
}

/* ===== ФОН ===== */
.page-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;

    background-image: url("foto/Rare/fonchik.JPG");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;

    z-index: -1;
}

/* ===== КОНТЕЙНЕР ===== */
.container {
    max-width: 1200px;
    margin: 60px auto;
    padding: 50px;
    border-radius: 20px;

    background: rgba(43, 43, 43, 0.75);
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);

    animation: fadeUp 1s ease forwards;
    opacity: 0;
    transform: translateY(40px);
}

/* ===== СЕТКА ===== */
.grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 25px;
}
.image-wrap {
    position: relative;
    width: 100%;
    height: 320px;
}

/* основное фото */
.photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* PNG рамка снизу */
.frame {
    position: absolute;
    left: 0;
    bottom: -45px; /* чуть ниже картинки */

    width: 100%;
    height: auto;

    z-index: 2;
    pointer-events: none;
}
/* ===== КАРТОЧКА ===== */
.rare-card {
    background: #1e1e1e;
    border-radius: 10px;
    overflow: hidden;
    text-align: center;
    cursor: pointer;
    position: relative;

    opacity: 0;
    animation: fadeUp 0.8s ease forwards;

    transition: transform 0.35s ease, box-shadow 0.35s ease;
    will-change: transform;
}

/* hover */
.rare-card:hover {
    transform: translateY(-12px);
    box-shadow: 0 18px 35px rgba(0,0,0,0.6);
    z-index: 5;
}

/* картинка */
.rare-card img {
    width: 100%;
    height: 320px;
    object-fit: cover;
    display: block;
    
}

/* затемнение */
.rare-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(139, 0, 0, 0.4);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.rare-card:hover::after {
    opacity: 1;
}

/* текст */
.rare-card p {
    padding: 15px;
    font-size: 14px;
    color: #ddd;
}

/* ===== МОДАЛКА ===== */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;

    background: rgba(0,0,0,0.7);
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background: #1e1e1e;
    width: 700px;
    border-radius: 15px;
    padding: 20px;
    position: relative;
    color: #ddd;
}

.modal-images {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin: 20px 0;
}

.modal-images img {
    width: 100%;
    height: 360px;
    object-fit: cover;
    border-radius: 8px;
}

/* крестик */
.close {
    position: absolute;
    right: 15px;
    top: 10px;
    cursor: pointer;
    font-size: 20px;
    color: var(--second-accent);
}

/* ===== РАЗДЕЛИТЕЛЬ ===== */
.divider {
    width: 80px;
    height: 3px;
    background: var(--second-accent);
    margin: 60px auto;
    border-radius: 2px;
}

/* ===== ТЕКСТОВЫЕ БЛОКИ ===== */
.extra-section {
    text-align: center;
    width: fit-content;
    margin: 30px auto;
    color: #ddd;
}

.extra-section h3 {
    margin-bottom: 15px;
    font-size: 24px;
    color: var(--second-accent);
}

.extra-section p {
    font-size: 18px;
    line-height: 1.6;
    color: #bbb;
}

/* ===== ЗАГОЛОВКИ БЛОКОВ ===== */
.title-box {
    background: #1e1e1e;
    padding: 25px 40px;
    margin: auto auto 60px auto;
    width: fit-content;
    text-align: center;
    border-radius: 14px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    color: var(--second-accent);
}
 
/* доп фото */
.dop-foto {
display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 15px;
  max-width: 1200px;
  margin: 20px auto 0;
  justify-items: center;
  align-items: center;
}
.dop-foto img {
    width: 100%;
    height: 360px;
    object-fit: cover;
    border-radius: 8px;
justify-items: center;
}

.card span {
    font-size: 18px;
}
.card span {
    line-height: 1.3;
    padding: 5px 8px;
    width: 90%;
}
.card span {
    font-size: clamp(10px, 1vw, 13px);
}
 

/* ===== АНИМАЦИЯ ===== */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== АДАПТИВ ===== */
@media (max-width: 1000px) {
    .grid {
        grid-template-columns: repeat(2, 1fr);
    }
}