/*
 Theme Name:   Tutto Mangiamo
 Template:     hello-elementor
 Version:      1.0.0
*/
/* === Post Grid: Base Layout for Desktop === */
.custom-post-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

/* === Post Card Styling === */
.post-card {
    position: relative;
    height: 300px;
    background-size: cover;
    background-position: center;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    transition: transform 0.3s;
}

.post-card:hover {
    transform: scale(1.02);
}

/* === Overlay Content Centered === */
.post-card .overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 20px;
    background: rgba(0, 0, 0, 0.4); /* dark overlay */
    text-align: center;
    color: #fff;
}

/* === Title Styling === */
.post-card h2 {
    font-size: 1.5rem;
    margin: 0 0 8px 0;
    color: #fff;
}

/* === Read Time Text === */
.read-time {
    font-size: 0.9rem;
    margin-bottom: 12px;
    display: block;
    opacity: 0.9;
}

/* === Read More Button === */
.read-more {
    background: #717744;
    color: white;
    padding: 8px 18px;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 500;
    transition: background 0.3s;
}

.read-more:hover {
	color: white;
    background: #373D20;
}

/* === Responsive: Tablets (≤1024px) === */
@media (max-width: 1024px) {
    .custom-post-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .post-card {
        height: 260px;
    }

    .post-card h2 {
        font-size: 1.3rem;
    }
}

/* === Responsive: Mobile Devices (≤768px) === */
@media (max-width: 768px) {
    .custom-post-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .post-card {
        height: 220px;
    }

    .post-card h2 {
        font-size: 1.1rem;
    }

    .read-more {
        padding: 6px 14px;
        font-size: 0.9rem;
    }
}

/* Tilt Card */

        .font-serif-display {
            font-family: 'Simonetta', serif;
        }

        .card-container {
            position: relative;
            display: block;
            width: 100%;
            max-width: 380px;
            aspect-ratio: 9 / 15.5;
            max-height: 90vh;
            border-radius: 1.75rem;
            overflow: hidden;
            background-size: cover;
            background-position: center;
            box-shadow:
                0 0 0 2px rgba(255, 214, 102, 0.4),
                0 0 25px 8px rgba(255, 214, 102, 0.15);
            transform-style: preserve-3d;
            transition: transform 0.6s cubic-bezier(0.23, 1, 0.32, 1),
                        box-shadow 0.4s ease-out,
                        background-size 1.5s ease-out;
            cursor: grab;
            will-change: transform, box-shadow, background-size;
        }

@media (max-width: 767px) {
	.card-container {
		height: 100%;
		max-height: 400px;
		align-items: center;
		justify-content: center;
	}
}

        .card-container:hover {
            box-shadow:
                0 0 0 3px rgba(255, 214, 102, 0.6),
                0 0 35px 12px rgba(255, 214, 102, 0.25);
        }

        .inner-border-overlay {
            position: absolute;
            inset: 14px;
            border-radius: 1.375rem;
            pointer-events: none;
            z-index: 10;
            box-shadow:
                inset 0.5px 0.5px 1.5px rgba(255, 235, 180, 0.6),
                inset -1px -1px 1px rgba(160, 110, 0, 0.5),
                inset 3px 3px 6px rgba(0, 0, 0, 0.25);
            transform: translateZ(30px);
            will-change: transform;
            border: 1px solid rgba(255, 214, 102, 0.1);
        }

        .content-area {
            position: absolute;
            inset: 14px;
            border-radius: 1.375rem;
            overflow: hidden;
            display: flex;
            flex-direction: column;
            justify-content: flex-end;
            z-index: 5;
            transform: translateZ(60px);
            will-change: transform;
        }

        .card-badge {
            position: absolute;
            top: 1rem;
            right: 1rem;
            background: rgba(255, 123, 0, 0.85);
            border-radius: 9999px;
            padding: 0.5rem 1rem;
            color: #fff;
            font-size: 0.75rem;
            font-weight: 600;
            letter-spacing: 0.025em;
            display: flex;
            align-items: center;
            gap: 0.5rem;
            box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
            transform: translateZ(70px);
            border: 1px solid rgba(255, 255, 255, 0.3);
            z-index: 25;
            will-change: transform;
        }

        .card-badge svg {
            width: 1em;
            height: 1em;
        }


        .gradient-overlay {
            position: absolute;
            bottom: 0; left: 0; right: 0;
            height: 75%;
            background: linear-gradient(to top, rgba(10, 10, 10, 0.9) 0%, rgba(10, 10, 10, 0.65) 50%, transparent 100%);
            pointer-events: none;
            z-index: 15;
            transform: translateZ(5px);
            will-change: transform;
        }

        .text-block {
            position: relative;
            z-index: 20;
            color: #f8fafc;
            text-align: center;
            text-shadow: 0 2px 4px rgba(0,0,0,0.5);
            transform: translateZ(25px);
            will-change: transform;
        }

        .text-block h1 {
            letter-spacing: 0.025em;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 0.5rem;
        }

        .text-block p {
            color: #cbd5e1;
        }

        .card-button {
            position: relative;
            z-index: 20;
            background: linear-gradient(145deg, #CC6200, #FF7B00);
            color: #fff;
            font-weight: 600;
            padding: 0.75rem 1.75rem;
            border-radius: 9999px;
            text-align: center;
            width: auto;
            min-width: 190px;
            max-width: 85%;
            margin-left: auto;
            margin-right: auto;
            transition: all 0.3s ease;
            border: none;
            box-shadow:
                inset 2px 2px 4px rgba(160, 110, 0, 0.6),
                inset -2px -2px 4px rgba(255, 245, 200, 0.5),
                0 1px 2px rgba(0,0,0,0.1);
            transform: translateZ(40px);
            will-change: transform, box-shadow, background;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 0.75rem;
            letter-spacing: 0.025em;
            margin-top: 1rem;
        }

        .card-button:hover {
            background: linear-gradient(145deg, #feec80, #fde047);
            box-shadow:
                inset 2px 2px 5px rgba(160, 110, 0, 0.5),
                inset -2px -2px 5px rgba(255, 245, 200, 0.6),
                0 2px 4px rgba(0,0,0,0.15);
            transform: translateZ(40px) translateY(-2px);
            color: #3f2810;
        }

        .card-button:active {
            background: linear-gradient(145deg, #facc15, #eab308);
            box-shadow:
                inset -2px -2px 4px rgba(160, 110, 0, 0.6),
                inset 2px 2px 4px rgba(255, 245, 200, 0.5),
                0 0 0 rgba(0,0,0,0);
            transform: translateZ(40px) translateY(0px);
        }

.glassmorphism {
    background: rgba( 0, 0, 0, 0.5 );
box-shadow: 0 8px 32px 0 rgba( 31, 38, 135, 0.37 );
backdrop-filter: blur( 4px );
-webkit-backdrop-filter: blur( 4px );
border-radius: 10px;
border: 1px solid rgba( 255, 255, 255, 0.18 );
}