/* Fonts */
.font-playfair { font-family: 'Playfair Display', serif; }
.font-inter { font-family: 'Inter', sans-serif; }

/* Scrollbar */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #09090b; }
::-webkit-scrollbar-thumb { background: #f59e0b33; border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: #f59e0b66; }

html { scroll-behavior: smooth; }

/* Navbar glass */
#navbar.scrolled {
    background: rgba(9, 9, 11, 0.85);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255,255,255,0.05);
    box-shadow: 0 4px 30px rgba(0,0,0,0.3);
}

/* Animations */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(40px); }
    to { opacity: 1; transform: translateY(0); }
}
.animate-fadeUp { animation: fadeUp 1s ease-out forwards; }

@keyframes cardIn {
    from { opacity: 0; transform: translateY(30px) scale(0.97); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
.card-animate {
    opacity: 0;
    animation: cardIn 0.5s ease-out forwards;
}

/* Pizza Card */
.pizza-card {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 1rem;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}
.pizza-card:hover {
    border-color: rgba(245, 158, 11, 0.25);
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.3), 0 0 60px rgba(245, 158, 11, 0.06);
}
.pizza-card .card-img {
    width: 100%;
    aspect-ratio: 16/10;
    object-fit: cover;
    transition: transform 0.6s ease;
}
.pizza-card:hover .card-img { transform: scale(1.08); }
.pizza-card .card-body { padding: 1.25rem; }
.pizza-card .card-title {
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 1rem;
    color: #fff;
    margin-bottom: 0.35rem;
}
.pizza-card .card-desc {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.35);
    line-height: 1.5;
    margin-bottom: 0.75rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.pizza-card .card-price {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: 1.25rem;
    color: #f59e0b;
}
.pizza-card .badge-popular {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: #000;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    z-index: 2;
}
.pizza-card .img-wrapper {
    overflow: hidden;
    position: relative;
}
.pizza-card .img-wrapper::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 40%;
    background: linear-gradient(to top, rgba(9,9,11,1), transparent);
    pointer-events: none;
}

.order-btn {
    border: 1px solid rgba(245, 158, 11, 0.4);
    color: #fcd34d;
    background: rgba(245, 158, 11, 0.08);
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding: 0.45rem 0.8rem;
    border-radius: 999px;
    transition: all 0.25s ease;
}
.order-btn:hover {
    background: rgba(245, 158, 11, 0.18);
    border-color: rgba(245, 158, 11, 0.6);
}

.cart-fab {
    position: fixed;
    right: 1.2rem;
    bottom: 1.2rem;
    z-index: 60;
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    border: 1px solid rgba(245, 158, 11, 0.4);
    border-radius: 999px;
    padding: 0.78rem 1.05rem;
    background: #f59e0b;
    color: #111827;
    font-weight: 800;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.35);
}

.site-modal {
    position: fixed;
    inset: 0;
    z-index: 80;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}
.site-modal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.68);
    backdrop-filter: blur(2px);
}
.site-modal-card {
    position: relative;
    width: min(720px, 96vw);
    max-height: 92vh;
    overflow: auto;
    border-radius: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: #18181b;
    padding: 1rem;
}
.site-modal-card-large {
    width: min(860px, 98vw);
}
.site-modal-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.65rem;
}
.modal-close-btn {
    width: 2.2rem;
    height: 2.2rem;
    border-radius: 0.6rem;
    border: 1px solid rgba(255, 255, 255, 0.14);
    color: #fff;
    background: rgba(255, 255, 255, 0.05);
    font-weight: 700;
}

.checkout-input {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.13);
    color: #fff;
    border-radius: 0.75rem;
    padding: 0.72rem 0.82rem;
    outline: none;
}
.checkout-input::placeholder {
    color: rgba(255, 255, 255, 0.42);
}
.checkout-input:focus {
    border-color: rgba(245, 158, 11, 0.6);
    box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.16);
}

.builder-scroll {
    max-height: 220px;
    overflow: auto;
    padding-right: 0.2rem;
}
.builder-option {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 0.7rem;
    padding: 0.6rem 0.7rem;
    margin-bottom: 0.5rem;
    background: rgba(255, 255, 255, 0.03);
    cursor: pointer;
}
.builder-option.selected {
    border-color: rgba(245, 158, 11, 0.65);
    background: rgba(245, 158, 11, 0.1);
}
.builder-option.disabled {
    opacity: 0.5;
}
.builder-option-body {
    flex: 1;
}
.builder-option-body small {
    display: block;
    color: rgba(255, 255, 255, 0.62);
    font-size: 0.75rem;
    margin-top: 0.1rem;
}

.builder-inline-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}
.builder-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.42rem;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 0.45rem 0.75rem;
    font-size: 0.77rem;
    color: rgba(255, 255, 255, 0.82);
    background: rgba(255, 255, 255, 0.04);
    cursor: pointer;
}
.builder-chip.active {
    border-color: rgba(245, 158, 11, 0.65);
    color: #fde68a;
    background: rgba(245, 158, 11, 0.12);
}
.builder-chip.disabled {
    opacity: 0.5;
}
.builder-chip input {
    accent-color: #f59e0b;
}

.builder-summary {
    margin-top: 0.95rem;
    border: 1px solid rgba(255, 255, 255, 0.13);
    border-radius: 0.75rem;
    background: rgba(255, 255, 255, 0.03);
    padding: 0.7rem;
}
.builder-summary p {
    margin-top: 0.25rem;
    color: rgba(255, 255, 255, 0.82);
    font-size: 0.85rem;
}
.builder-total {
    color: #fcd34d !important;
    font-weight: 700;
}

.checkout-items {
    max-height: 270px;
    overflow: auto;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.8rem;
    padding: 0.65rem;
    background: rgba(255, 255, 255, 0.03);
}
.checkout-row {
    border-bottom: 1px dashed rgba(255, 255, 255, 0.12);
    padding: 0.5rem 0;
}
.checkout-row:last-child {
    border-bottom: none;
}
.checkout-row-top {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
}
.checkout-row-top small {
    display: block;
    color: rgba(255, 255, 255, 0.62);
    font-size: 0.74rem;
}

.qty-controls {
    margin-top: 0.42rem;
    display: inline-flex;
    align-items: center;
    gap: 0.42rem;
}
.qty-controls button {
    width: 1.6rem;
    height: 1.6rem;
    border-radius: 0.38rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
    font-weight: 700;
}
.qty-controls span {
    min-width: 1.1rem;
    text-align: center;
    font-size: 0.86rem;
}

.checkout-totals {
    margin-top: 0.7rem;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 0.8rem;
    padding: 0.7rem;
    background: rgba(255, 255, 255, 0.03);
}
.checkout-totals > div {
    display: flex;
    justify-content: space-between;
    color: rgba(255, 255, 255, 0.88);
    margin-bottom: 0.3rem;
}
.checkout-totals > div:last-child {
    margin-bottom: 0;
}
.checkout-total {
    font-size: 1.1rem;
    font-weight: 700;
    color: #fff !important;
}

.checkout-feedback {
    min-height: 1.2rem;
    margin-top: 0.45rem;
    color: rgba(255, 255, 255, 0.75);
    font-size: 0.9rem;
}
.checkout-feedback.error {
    color: #fca5a5;
}
.checkout-feedback.success {
    color: #86efac;
}

@media (max-width: 640px) {
    .site-modal-card,
    .site-modal-card-large {
        width: 98vw;
        max-height: 95vh;
    }
    .cart-fab {
        right: 0.8rem;
        bottom: 0.8rem;
    }
}
