body{
    background:#0d0d0d;
    color:white;
    font-family:Arial, sans-serif;
    margin:0;
}

.bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;

    background:
        linear-gradient(rgba(0,0,0,0.35), rgba(0,0,0,0.35)),
        url('/ordina6/images/background1.png');

    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;

    z-index: -1;
    pointer-events: none;
}

/* IMPORTANTISSIMO: il body NON deve avere background */
body {
    background: transparent !important;
}

header{
    background:black;
    padding:10px 20px;
    text-align:center;
    border-bottom:1px solid gold;
    margin-bottom:0;
}

header h1{
    margin:0;
    font-size:32px;
}

.container{
    padding:20px;
	padding-bottom:120px;
}

table{
    width:100%;
    border-collapse:collapse;
    margin-top:20px;
}

th, td{
    border:1px solid #333;
    padding:12px;
    text-align:center;
}

th{
    background:#1a1a1a;
    color:gold;
}

input[type="text"], 
textarea{
    width:100%;
    padding:10px;
    margin-top:10px;
    background:#111;
    color:white;
    border:1px solid #333;
}

button{
    background:gold;
    color:black;
    border:none;
    padding:12px 20px;
    margin-top:15px;
    cursor:pointer;
    font-weight:bold;
}

.summary{
    margin-top:30px;
}

.login-page{
    display:flex;
    justify-content:center;
    align-items:center;
    height:100vh;
}

.login-box{
    width:320px;
    background:#111;
    padding:30px;
    border:1px solid gold;
}

.qty {
    width: 60px !important;
    text-align: center;
}

#search{
    width:90%;
    max-width:400px;
    margin:auto;
	font-size:16px;
	border:1px solid #d4af37;
	position:center;
	
}

textarea {
    width: 100%;
    max-width: 500px;
}
.category-row td{
    background: linear-gradient(90deg,#b8860b,#d4af37,#b8860b);
    color: #fff;
    font-size: 18px;
    font-weight: 700;
    text-align: center;
    padding: 14px;
    letter-spacing: 2px;
    text-transform: uppercase;
    border: none;
}

.category-row:hover td{
    background: linear-gradient(90deg,#b8860b,#d4af37,#b8860b);
}

.category-row{
    pointer-events:none;
}
.customer-data{
    display:flex;
    flex-direction:column;
    gap:10px;
    margin-bottom:20px;
}

.customer-data input{
    padding:12px;
    border:1px solid #d4af37;
    border-radius:8px;
    font-size:16px;
    width:100%;
    box-sizing:border-box;
}

.loading-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.75);
    z-index: 999999999;

    display: none !important;

    justify-content: center;
    align-items: center;
    flex-direction: column;

    color: white;
    font-size: 18px;
}

.loading-overlay.active {
    display: flex !important;
}

.spinner {
    width: 55px;
    height: 55px;
    border: 5px solid #ccc;
    border-top: 5px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 15px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

#loadingOverlay {
	display:none;
}
.product-grid{

    display:grid;

    grid-template-columns:
        repeat(auto-fill,minmax(340px,340px));

    justify-content:center;

    gap:25px;

    margin-top:25px;

}

.category-title{
    grid-column:1 / -1;

    background:linear-gradient(
        90deg,
        #8f6b00,
        #d4af37,
        #8f6b00
    );

    color:white;
    padding:15px;
    border-radius:12px;

    text-align:center;
    font-size:20px;
    font-weight:bold;
    letter-spacing:2px;
}

#categorySelect{
    width:90%;
	
	max-width:400px;

    margin:auto;

    display:block;

    padding:14px;

    border-radius:12px;

    background:#111;

    color:white;

    border:1px solid #d4af37;

    font-size:16px;

}

.product-card{

    background:#141414;
	height:auto;

    border:1px solid #2d2d2d;

    border-radius:16px;

    padding:14px;

    transition:0.25s;

    box-shadow:
    0 5px 15px rgba(0,0,0,.25);

}

.product-card:hover{

    transform:translateY(-4px);

    border-color:#d4af37;

    box-shadow:
    0 10px 25px rgba(212,175,55,.15);

}

.product-code{

    color:#EE82EE;

    font-size:14px;

    margin-bottom:10px;

}

.product-name{

    font-size:18px;

    font-weight:bold;

    margin-bottom:10px;

}

.product-info{

    color:#bbb;

    font-size:14px;

    line-height:1.7;

}

.product-price{

    color:#d4af37;

    font-size:28px;

    font-weight:bold;

    margin-top:10px;

    margin-bottom:10px;

}

.product-price::before{
    content:"€ ";
}

.product-order{

    display:flex;

    justify-content:space-between;

    align-items:center;

    gap:10px;
	
	margin-top:15px;
    
	font-size:24px;

    font-weight:bold;

    color:#d4af37;

}

.product-order .qty{

    width:80px !important;

    height:42px;

    border-radius:10px;

    border:1px solid #444;

    background:#1c1c1c;

    color:white;

}

.row-total{

    font-size:18px;

    font-weight:bold;

    color:white;

}
.qty-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.qty-controls button {
    width: 48px;
    height: 48px;
    margin: 0;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: linear-gradient(135deg, #d4af37, #f5d76e);
    color: #000;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(212, 175, 55, 0.35);
}

.qty-controls button:hover {
    transform: scale(1.05);
}

.qty-controls .qty {
    width: 90px !important;
    height: 48px;
    margin: 0;
    padding: 0;
    border: 1px solid #d4af37;
    border-radius: 14px;
    background: #1a1a1a;
    color: white;
    text-align: center;
    font-size: 22px;
    font-weight: bold;
    box-sizing: border-box;
}

.qty::-webkit-outer-spin-button,
.qty::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.qty {
    -moz-appearance: textfield;
    appearance: textfield;
}

.discount-badge{

    display:inline-block;

    background:linear-gradient(
        135deg,
        #d4af37,
        #f5d76e
    );

    color:#000;

    font-weight:bold;

    font-size:14px;

    padding:6px 12px;

    border-radius:20px;

    margin-top:10px;
    margin-bottom:10px;

    box-shadow:
        0 3px 10px rgba(212,175,55,.35);

}

.product-listino{

    color:#999;

    font-size:14px;

    text-decoration:line-through;

}

.sticky-cart{

    position:fixed;

    left:0;
    right:0;
    bottom:0;
    background:#111;
    border-top:2px solid #d4af37;
    padding:12px 15px;
    display:flex;
    justify-content:space-between;
    align-items:center;
    gap:15px;
    z-index:9999;
    box-shadow:
        0 -5px 20px rgba(0,0,0,.4);

}

.sticky-total{

    color:white;

    font-size:18px;
    font-weight:bold;
	white-space:nowrap;
	line-height:1;
}

#stickyTotal{

    color:#d4af37;

}

.sticky-btn{

    margin:0 !important;

    padding:12px 20px;

    border-radius:10px;

    font-size:15px;

}
.summary button{
    display:none;
}

.product-image{

    width:100%;

    height:300px;

    object-fit:contain;

    padding:0;

    background:transparent;

}

.product-card:hover .product-image{

    transform:scale(1.03);

    transition:.25s;

}

@media (min-width: 1200px){

    .product-grid{

        grid-template-columns:
        repeat(4, 340px);

        justify-content:center;

    }

}



.filter-btn{

    background:#1a1a1a;
    color:white;

    border:1px solid #444;

    border-radius:30px;

    padding:10px 18px;

    cursor:pointer;

}

.filter-btn.active{

    background:#d4af37;
    color:black;
    border-color:#d4af37;

}


.cart-drawer{

    position:fixed;
    top:0;
    right:-420px;
    width:380px;
    max-width:90vw;
    height:100vh;
    background:#111;
    border-left:2px solid #d4af37;
    z-index:100000;
    transition:right .3s ease;
    overflow-y:auto;
    box-sizing:border-box;
    padding:20px;

}

.cart-drawer.open{

    right:0;

}

.cart-header{

    display:flex;

    justify-content:space-between;

    align-items:center;

    margin-bottom:20px;

}

.cart-header h3{

    margin:0;

    color:#d4af37;

}

.cart-icon {
    width: 20px;
    height: 20px;
    fill: currentColor;
    vertical-align: middle;
    margin-right: 6px;
}

#closeCart{

    background:none;

    border:none;

    color:white;

    font-size:24px;

    cursor:pointer;

    padding:0;

    margin:0;

}

.cart-item{

    display:flex;

    justify-content:space-between;

    gap:10px;

    padding:12px 0;

    border-bottom:1px solid #333;

}

.cart-item strong{

    color:white;

}

.cart-item small{

    color:#999;

}

.sticky-cart-link{

    display:flex;

    flex-direction:column;

    align-items:flex-start;

    justify-content:center;

    gap:3px;

    cursor:pointer;

    color:#d4af37;

    font-weight:bold;

}

.sticky-cart-link:hover{

    background:#252525;

}

.sticky-cart-link #cartCount{

    background:#d4af37;

    color:black;

    min-width:24px;

    height:24px;

    border-radius:50%;

    display:flex;

    align-items:center;

    justify-content:center;

    font-size:13px;

    font-weight:bold;

}
#cartCount{
    background:#d4af37;
    color:#000;
    min-width:20px;
    height:20px;
    border-radius:50%;
    display:flex;
    align-items:center;
    justify-content:center;
    font-size:12px;
    font-weight:bold;
}

.clear-cart-btn{
    width:100%;
    margin-top:20px;
    padding:12px;
    background:#1a1a1a;
    color:white;
    border:1px solid #d4af37;
    border-radius:10px;
    font-size:15px;
    font-weight:bold;
    cursor:pointer;

    display:flex;
    align-items:center;
    justify-content:center;
    gap:8px;
}

.trash-icon{
    width:18px;
    height:18px;
    fill:currentColor;
}

.clear-cart-btn:hover{
    background:#d4af37;
    color:black;
}

.cart-controls {
    display: flex;
    align-items: center;
    gap: 6px;
}

.cart-controls button {
    width: 22px;
    height: 22px;
    font-size: 14px;
    padding: 0;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.error-field{
    border:2px solid #ff4d4d !important;
}

.top-bar{
    margin:auto;
	position:sticky;
    top:0;
    z-index:10000;

    display:flex;
    gap:10px;

    padding:10px 15px;

    background:#0d0d0d;

    border-bottom:1px solid #333;
}

.top-bar input,
.top-bar select{
    flex:1;
	margin:auto;
    padding:0px 12px;
	height:50px;
    background:#111;
    color:white;
	border:1px solid #444;
    border-radius:10px;
	min-width:0;
	box-sizing:border-box;
}

.promo-banner {
    width: 100%;
    max-width: 1400px;
    margin: 20px auto;
    padding: 0 15px;
    box-sizing: border-box;
}

.promo-banner img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 16px;
    box-shadow: 0 8px 25px rgba(0,0,0,.35);
}

.sticky-total {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.sticky-iva {
    font-size: 10px;
    color: #d0d0d0;
    margin-top: -2px;
    line-height: 1;
}

/* BANNER AREA PROFESSIONISTI */
.professional-banner {
    max-width: 1100px;
    margin: 18px auto 25px;
    padding: 18px 22px;
    background: #111;
    border: 1px solid #d4af37;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    box-sizing: border-box;
}
.professional-text {
    display: flex;
    flex-direction: column;
    gap: 6px;
    color: #fff;
}
.professional-text strong {
    color: #d4af37;
    font-size: 15px;
}
.professional-text span {
    font-size: 13px;
}
.professional-button {
    display: inline-block;
    padding: 12px 18px;
    background: #d4af37;
    color: #111;
    text-decoration: none;
    font-weight: bold;
    font-size: 13px;
    border-radius: 5px;
    text-align: center;
    white-space: nowrap;
}
.professional-button:hover {
    background: #f0d36b;
}
@media (max-width: 600px) {
    .professional-banner {
        margin: 15px 12px 20px;
        flex-direction: column;
        text-align: center;
    }
    .professional-button {
        width: 100%;
        box-sizing: border-box;
    }
}