/*
Theme Name: Avanti Elite Starter 7.1
Theme URI: https://avantipizza.ro
Description: The absolute definitive edition: High-conversion marketing platform with 'Hard Mode' gamification (1% win rate), artisanal Italian branding, fully categorized menu engine, and full RO/EN support. Clean, stable, and ready for production.
Author: Avanti Digital
Author URI: https://avantipizza.ro
Version: 7.1.0
Requires at least: 6.0
Tested up to: 6.9
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: avanti
Tags: restaurant, food, pizza, luxury, artisanal, gamification, bilingual, translation-ready, theme-options, featured-images
*/

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,500;0,700;1,500&family=Jost:wght@400;500;600&display=swap');

:root {
    /* Brand Colors - Premium Italian Artisanal Aesthetic */
    --avanti-red: #c92a2a; /* Deep tomato red */
    --avanti-dark: #1b1b1b; /* Charcoal, softer than pitch black */
    --avanti-white: #ffffff;
    --avanti-gold: #cfa864; /* Elegant matte gold */
    --avanti-gold-glow: rgba(207, 168, 100, 0.3);
    
    /* System Colors */
    --bg-color: #FDF9F1; /* Warm parchment beige */
    --bg-card: #ffffff;
    --text-primary: #2b2b2b;
    --text-secondary: #6e6b65;
    --border-color: #e8e2d5;

    /* Typography */
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Jost', -apple-system, sans-serif;
    
    /* Metrics & Premium Effects */
    --header-height: 65px; 
    --bottom-bar-height: 70px;
    --border-radius: 12px;
    --border-radius-lg: 24px;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --gold-shadow: 0 0 15px var(--avanti-gold-glow);
}

/* Base Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-color);
    background-image: url('images/background.png');
    background-attachment: fixed;
    background-size: cover;
    background-position: center;
    color: var(--text-primary);
    line-height: 1.4;
    font-size: 15px;
    -webkit-font-smoothing: antialiased;
    padding-top: var(--header-height);
}

/* Sophisticated Hero — Elite Starter 4.0 */
.hero-premium {
    background: linear-gradient(135deg, var(--avanti-dark) 0%, #3a0d0d 100%);
    color: #fff;
    padding: 60px 5%;
    text-align: center;
    position: relative;
    overflow: hidden;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.hero-premium::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: url('images/hero-pattern.png');
    opacity: 0.1;
}
.hero-content {
    max-width: 800px;
    z-index: 10;
}
.hero-title {
    font-size: clamp(2rem, 7vw, 3.8rem);
    font-weight: 800;
    margin-bottom: 20px;
}
.hero-subtitle {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-bottom: 30px;
    line-height: 1.5;
}
.hero-actions {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

/* Button Refinement — Elite Starter */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 18px 45px;
    border-radius: 50px;
    font-weight: 700;
    transition: var(--transition);
    cursor: pointer;
    font-size: 1.05rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}
.btn-primary {
    background: var(--avanti-red);
    color: #fff;
    border: none;
    box-shadow: 0 10px 25px rgba(201, 42, 42, 0.3);
}
.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(201, 42, 42, 0.4);
}
.btn-outline {
    background: transparent;
    color: #fff;
    border: 2px solid rgba(255,255,255,0.3);
}
.btn-outline:hover {
    background: #fff;
    color: var(--avanti-dark);
    border-color: #fff;
}

/* Offers Page Styles */
.page-offers {
    padding-top: 60px;
}
.offers-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 5%;
}
.offers-section {
    margin-bottom: 100px;
}
.category-title {
    font-size: 1.85rem;
    color: var(--avanti-red);
    margin-bottom: 30px;
    font-style: italic;
    border-left: 4px solid var(--avanti-red);
    padding-left: 15px;
}
.offers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 40px;
}
.offers-grid-2 {
    grid-template-columns: repeat(auto-fit, minmax(420px, 1fr));
}
.offer-card {
    position: relative;
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    aspect-ratio: 16/10;
    background: var(--avanti-dark);
    transition: var(--transition);
}
.offer-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 30px 60px rgba(0,0,0,0.15);
}
.offer-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s ease;
}
.offer-card:hover img {
    transform: scale(1.08);
}
.offer-cta-overlay {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, transparent 100%);
    padding: 60px 20px 30px;
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-align: center;
    opacity: 0;
    transform: translateY(20px);
    transition: var(--transition);
}
.offer-card:hover .offer-cta-overlay {
    opacity: 1;
    transform: translateY(0);
}
.section-subtitle {
    text-align: center;
    max-width: 900px;
    margin: 0 auto 80px;
    font-size: 1.15rem;
    line-height: 1.5;
    color: var(--text-secondary);
}

@media(min-width: 768px) {
    body { padding-bottom: 0; }
}

.site-header {
    height: var(--header-height);
    background: #fff;
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 5%;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}
.brand-logo img {
    max-height: 40px;
    width: auto;
    display: block;
}
.nav-links {
    display: flex;
    gap: 25px;
}
.nav-links a {
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
    color: var(--text-primary);
}
.header-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Mobile Drawer Overlay */
.mobile-drawer {
    position: fixed;
    top: 0; left: -100%;
    width: 80%; height: 100dvh;
    background: var(--avanti-dark);
    z-index: 3000;
    transition: var(--transition);
    padding: 60px 40px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}
.mobile-drawer.active {
    left: 0;
}
.mobile-drawer a {
    color: #fff;
    font-size: 1.4rem;
    font-family: var(--font-heading);
    font-style: italic;
}
.drawer-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.6);
    z-index: 2500;
    opacity: 0; visibility: hidden;
    transition: var(--transition);
}
.drawer-overlay.active {
    opacity: 1; visibility: visible;
}

/* Category Filter — Flush Left Alignment & Premium Spacing */
.category-scroller {
    display: flex;
    gap: 15px;
    overflow-x: auto;
    padding: 10px 5% 30px; /* Aligned with menu-grid padding */
    scrollbar-width: none;
    justify-content: flex-start;
}
@media(min-width: 1024px) {
    .category-scroller { justify-content: flex-start; }
}
.category-scroller::-webkit-scrollbar { display: none; }
.category-pill {
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid var(--border-color);
    padding: 12px 40px; /* Big spaces between word and frame */
    border-radius: 50px;
    font-weight: 700;
    white-space: nowrap;
    transition: var(--transition);
    color: var(--text-secondary);
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 1px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}
.category-pill.active, .category-pill:hover {
    background: var(--avanti-red);
    color: #fff;
    border-color: var(--avanti-red);
}

/* App-Mode Horizontal Layout v8.0 */
.menu-section-container {
    margin-bottom: 50px;
    position: relative;
}
.section-title-app {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 800;
    margin: 30px 5% 20px;
    color: var(--avanti-dark);
    text-align: left;
    display: flex;
    align-items: center;
    gap: 10px;
}
.section-title-app::after {
    content: '';
    flex-grow: 1;
    height: 1px;
    background: rgba(0,0,0,0.05);
}

.products-row {
    display: flex;
    overflow-x: auto;
    gap: 20px;
    padding: 10px 5% 30px;
    scroll-snap-type: x mandatory;
    scrollbar-width: none; /* Hide scrollbar Firefox */
    -ms-overflow-style: none; /* Hide scrollbar IE/Edge */
    -webkit-overflow-scrolling: touch;
}
.products-row::-webkit-scrollbar {
    display: none; /* Hide scrollbar Chrome/Safari */
}

.product-card-app {
    flex: 0 0 300px; /* Fixed width for app feel */
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    padding: 20px;
    transition: var(--transition);
    scroll-snap-align: start;
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
}
.product-card-app:hover {
    transform: translateY(-8px);
    border-color: var(--avanti-gold);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.product-img-container {
    position: relative;
    width: 100%;
    aspect-ratio: 1/1;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.product-img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 10px 15px rgba(0,0,0,0.1));
}
.product-img-placeholder {
    font-size: 3rem;
    background: var(--bg-color);
    border-radius: 20px;
    width: 100%; height: 100%;
    display: flex; align-items: center; justify-content: center;
}

.badge-app {
    position: absolute;
    top: -5px;
    right: -5px;
    padding: 6px 14px;
    font-size: 0.7rem;
    font-weight: 800;
    border-radius: 50px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    z-index: 2;
}

.product-info-app {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}
.product-desc-app {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 20px;
    min-height: 2.7em;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-footer-app {
    margin-top: auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 15px;
    border-top: 1px solid rgba(0,0,0,0.05);
}
.product-price-app {
    display: flex;
    flex-direction: column;
}
.price-main {
    font-size: 1.4rem;
    font-weight: 900;
    color: var(--avanti-red);
}
.price-secondary {
    font-size: 0.7rem;
    opacity: 0.5;
    font-weight: 700;
}

.btn-app-cta {
    padding: 10px 24px;
    font-size: 0.8rem;
    font-weight: 800;
    border-radius: 50px;
    letter-spacing: 0.5px;
    box-shadow: var(--shadow-sm);
}

@media (max-width: 768px) {
    .product-card-app {
        flex: 0 0 250px;
        padding: 15px;
    }
    .section-title-app {
        font-size: 1.4rem;
    }
    .price-main {
        font-size: 1.2rem;
    }
}
.product-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--border-color);
    padding-top: 25px;
}
.product-price {
    width: 100%;
}
.price-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    text-align: center;
    margin-bottom: 10px;
    width: 100%;
}
.price-item {
    font-size: 0.85rem; /* Not very big font */
}
.price-label {
    display: block;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    font-size: 0.7rem;
    margin-bottom: 2px;
}
.price-value {
    display: block;
    font-weight: 800;
    color: var(--avanti-dark);
}

/* Reviews Styling — Sophisticated Grid */
.reviews-section {
    background: #fff; 
    padding: 120px 5%;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}
.reviews-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px;
    max-width: 1400px;
    margin: 0 auto;
}
.review-card {
    background: var(--bg-color);
    padding: 45px;
    border-radius: var(--border-radius-lg);
    border: 1px solid var(--border-color);
    transition: var(--transition);
}
.review-card:hover {
    transform: scale(1.03);
    box-shadow: 0 20px 50px rgba(0,0,0,0.06);
    background: #fff;
    border-color: var(--avanti-gold);
}
.review-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 25px;
}
.review-avatar {
    width: 60px; height: 60px;
    border-radius: 50%;
    border: 3px solid var(--avanti-gold);
    object-fit: cover;
}
.review-name { font-size: 1.3rem; font-weight: 700; color: var(--avanti-dark); }
.review-since { font-size: 0.85rem; color: var(--text-secondary); }
.review-rating { margin-bottom: 20px; display: flex; gap: 5px; }

.review-text {
    font-style: italic;
    color: var(--text-secondary);
    font-size: 1.1rem;
    line-height: 1.8;
    margin: 25px 0;
}
.trust-badge {
    display: inline-flex;
    align-items: center;
    color: #2fb344;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 1px;
    background: rgba(47, 179, 68, 0.05);
    padding: 6px 15px;
    border-radius: 20px;
}

/* Social & Footer Refinements */
.social-icon-circle {
    width: 40px; height: 40px;
    border-radius: 50%;
    background: rgba(255,255,255,0.05);
    display: flex; align-items: center; justify-content: center;
    transition: var(--transition);
    border: 1px solid rgba(255,255,255,0.1);
}
.social-icon-link:hover .social-icon-circle {
    background: var(--avanti-gold);
    transform: translateY(-3px);
    border-color: var(--avanti-gold);
}
.social-icon { 
    display: inline-block; width: 20px; height: 20px; 
    background-size: contain; background-repeat: no-repeat; filter: invert(1);
}

.footer-bottom {
    margin-top: 4rem; padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.05);
    color: #666; font-size: 0.85rem; text-align: center;
}

/* Back to Top Button Styling */
.back-to-top {
    position: fixed;
    bottom: 100px;
    right: 30px;
    background: var(--avanti-red);
    color: #fff;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: none;
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 1000;
}
.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}
.back-to-top:hover {
    transform: translateY(-5px);
    background: var(--avanti-dark);
}

/* Animations Logic */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: all 1s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.animate-on-scroll.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Pulsating CTA */
@keyframes pulseGlow {
    0% { box-shadow: 0 0 0 0 rgba(201, 42, 42, 0.4); }
    70% { box-shadow: 0 0 0 15px rgba(201, 42, 42, 0); }
    100% { box-shadow: 0 0 0 0 rgba(201, 42, 42, 0); }
}
.btn-pulse { animation: pulseGlow 2.5s infinite; }

@media (max-width: 768px) {
    .menu-grid { 
        grid-template-columns: repeat(2, 1fr); 
        gap: 12px;
        padding: 0 3%;
    }
    .product-card {
        padding: 10px;
    }
    .product-img {
        margin-bottom: 8px;
    }
    .product-title {
        font-size: 1.05rem;
        margin-bottom: 4px;
    }
    .product-desc {
        font-size: 0.85rem;
        margin-bottom: 12px;
        line-height: 1.4;
    }
    .product-price {
        font-size: 1.1rem;
    }
    .product-footer {
        padding-top: 10px;
    }
    .product-footer .btn {
        padding: 6px 12px;
        font-size: 0.75rem;
    }
}

/* SLEEK ELITE FOOTER — Minimalist Elegance over Background */
.site-footer {
    background: rgba(15, 15, 15, 0.96);
    backdrop-filter: blur(15px);
    color: #fff;
    padding: 90px 0 50px;
    position: relative;
    border-top: 1px solid rgba(255,255,255,0.05);
}
.footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 5%;
}
.footer-brand {
    text-align: center;
    margin-bottom: 70px;
}
.footer-logo {
    max-height: 45px;
    margin-bottom: 20px;
    filter: brightness(0) invert(1);
    opacity: 0.9;
}
.brand-tagline {
    font-size: 0.75rem;
    opacity: 0.4;
    letter-spacing: 4px;
    text-transform: uppercase;
    font-weight: 300;
}
.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 50px;
    margin-bottom: 70px;
    text-align: left;
}
.footer-col h4 {
    color: var(--avanti-gold);
    font-size: 0.85rem;
    margin-bottom: 30px;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 700;
}
.footer-links {
    list-style: none;
    padding: 0;
}
.footer-links li {
    margin-bottom: 15px;
}
.footer-links a {
    color: rgba(255,255,255,0.55);
    font-size: 0.85rem;
    transition: all 0.3s ease;
    text-decoration: none;
}
.footer-links a:hover {
    color: #fff;
    transform: translateX(5px);
    display: inline-block;
}
.footer-contact-minimal p {
    font-size: 0.85rem;
    opacity: 0.5;
    margin-bottom: 12px;
    line-height: 1.6;
}
.footer-tel {
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--avanti-gold);
    text-decoration: none;
}
.footer-social-bar {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-bottom: 50px;
    padding-top: 50px;
    border-top: 1px solid rgba(255,255,255,0.08);
}
.social-link-minimal {
    font-size: 0.7rem;
    font-weight: 800;
    letter-spacing: 2.5px;
    color: rgba(255,255,255,0.3);
    transition: var(--transition);
}
.social-link-minimal:hover {
    color: #fff;
}
.footer-compliance {
    display: flex;
    justify-content: center;
    gap: 25px;
    margin-bottom: 50px;
    opacity: 0.3;
    filter: grayscale(1);
    transition: opacity 0.3s ease;
}
.footer-compliance:hover { opacity: 0.6; }
.footer-compliance img {
    height: 24px;
}
.footer-bottom-minimal {
    font-size: 0.65rem;
    opacity: 0.25;
    text-align: center;
    letter-spacing: 1px;
}

@media(max-width: 768px) {
    .footer-grid { text-align: center; gap: 40px; }
    .site-footer { padding: 70px 0 40px; }
    .footer-tel { font-size: 1.1rem; }
    .reviews-grid { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 20px; }
    .review-card { min-width: 300px; scroll-snap-align: center; padding: 25px; }
    .back-to-top { bottom: 100px; right: 15px; }
    .hero-premium { min-height: 350px; padding: 40px 5%; }
    .hero-title { font-size: 2rem; }
    .desktop-only { display: none !important; }
}
