/* === WRAPPER: центрирование + адаптивная сетка === */
.agat-catalog {
    display: flex;
    flex-wrap: wrap;
    justify-content: center; /* центрируем карточки */
    gap: 2rem;
    margin-top: 2rem;
    perspective: 1600px; /* для 3D */
}

/* === CARD === */
.agat-card {
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 340px;

    background: var(--scrap-surface);
    border: 1px solid var(--scrap-border);
    backdrop-filter: blur(18px);

    border-radius: 1rem;
    overflow: hidden;
    text-decoration: none;
    color: var(--scrap-text);

    box-shadow: 0 14px 32px rgba(15,23,42,0.18);
    transition: transform .35s cubic-bezier(.22,.61,.36,1),
                box-shadow .35s ease,
                filter .35s ease;

    position: relative;
    transform-style: preserve-3d;
}

/* === PARALLELEPIPED SKEW === */
.agat-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;

    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255,255,255,0.12) 0%, transparent 40%);
    pointer-events: none;

    transform: skewX(-6deg);
    transform-origin: top left;
}

/* === ORANGE GLOW + 3D === */
.agat-card:hover {
    box-shadow:
        0 22px 48px rgba(15,23,42,0.32),
        0 0 22px rgba(255,140,0,0.55),
        0 0 42px rgba(255,140,0,0.35);
    filter: brightness(1.05);
    transform: translateY(-10px) rotateX(6deg) rotateY(-6deg);
}

/* === IMAGE === */
.agat-card-img {
    width: 100%;
    height: 180px;
    background-size: cover;
    background-position: center;
    position: relative;
}

/* === ICON (если нужно) === */
.agat-card-img::after {
    content: attr(data-icon);
    position: absolute;
    bottom: 12px;
    right: 12px;

    font-size: 2rem;
    color: rgba(255,255,255,0.85);
    text-shadow: 0 0 12px rgba(0,0,0,0.45);
}

/* === CONTENT === */
.agat-card-content {
    padding: 1.2rem 1.3rem;
    text-align: center;
}

.agat-card-content h3 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--scrap-primary-dark);
    line-height: 1.35;
}

/* === ADAPTIVE === */
@media (max-width: 1024px) {
    .agat-card {
        max-width: 300px;
    }
}

@media (max-width: 768px) {
    .agat-card {
        max-width: 100%;
        transform: none !important; /* отключаем 3D на мобилках */
    }

    .agat-card-img {
        height: 200px;
    }
}
.agat-card-icon {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    opacity: 0.45;
}

.agat-card-icon svg {
    width: 64px;
    height: 64px;
    fill: var(--agat-accent); /* рыже‑медный */
}
.agat-card {
    position: relative;
}
