:root {
    --color-primary: #8b4513; /* Marrone scuro */
    --color-secondary: #2c3e50; /* Grigio-blu scuro */
    --color-text-light: #f5f5dc; /* Beige */
    --color-text-dark: #333; /* Grigio scuro */
    --color-dark-bg: #1a1a1a; /* Nero profondo */
    --color-discord-blue: #7289da;
    --color-discord-green: #43b581;
    --color-discord-red: #f04747;
}

/* Stili Generali e per il Body */
body {
    font-family: 'Roboto', sans-serif;
    color: var(--color-text-light);
    background-color: var(--color-dark-bg);
    margin: 0;
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('img/background.png') no-repeat center center;
    background-size: cover;
    background-attachment: fixed;
    z-index: -2;
}

/* Stili Bootstrap sovrascritti */
.bg-dark {
    background-color: var(--color-dark-bg) !important;
}

.bg-secondary {
    background-color: var(--color-secondary) !important;
}

.text-white {
    color: var(--color-text-light) !important;
}

.text-brown-custom {
    color: var(--color-primary) !important;
}

/* --- Navigazione (Navbar) --- */
.navbar-custom {
    background-color: rgba(44, 62, 80, 0.3) !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.navbar-brand {
    height: 70px;
    display: flex;
    align-items: center;
}

.logo {
    height: 100px;
    width: auto;
    transition: transform 0.3s ease;
}

.logo:hover {
    transform: scale(1.05);
}

/* Stili per i link di navigazione */
.nav-link-custom {
    color: #fff;
    font-family: 'Cinzel', serif;
    font-weight: 700;
    text-transform: uppercase;
    transition: color 0.3s ease;
}

.nav-link-custom:hover {
    color: #D4AF37; /* Colore oro al passaggio del mouse */
}

.btn-primary {
    background-color: var(--color-primary);
    border-color: var(--color-primary);
}

.btn-primary:hover {
    background-color: #a0522d;
    border-color: #a0522d;
}

.btn-discord {
    background-color: var(--color-discord-blue);
    color: white !important;
    padding: 0.75rem 1.5rem;
    border-radius: 5px;
    font-weight: bold;
    text-decoration: none;
    transition: background-color 0.3s ease, transform 0.3s ease;
    display: flex;
    align-items: center;
}

.btn-discord:hover {
    background-color: #5d75d3;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Stile per l'area utente (dropdown) */
.nav-item.dropdown .dropdown-toggle {
    display: flex;
    align-items: center;
    padding: 0.5rem 0.75rem;
    color: #fff;
    font-family: 'Roboto', sans-serif;
    transition: background-color 0.3s ease;
    border-radius: 0.25rem;
}

.nav-item.dropdown .dropdown-toggle:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.dropdown-menu {
    background-color: #212529;
    border: 1px solid #D4AF37;
}

.dropdown-item {
    color: #fff;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.dropdown-item:hover {
    background-color: #2c3135;
    color: #D4AF37;
}

.dropdown-divider {
    border-top: 1px solid #D4AF37;
}

/* Stili ingranditi per l'avatar e il nome utente */
.nav-item.dropdown .dropdown-toggle img {
    width: 48px !important;
    height: 48px !important;
    border: 3px solid #D4AF37;
}

.nav-item.dropdown .dropdown-toggle span.d-lg-inline {
    font-size: 1.2rem;
    font-weight: bold;
    color: #D4AF37;
}

/* Stile per il pallino di notifica */
.notification-dot {
    position: absolute;
    top: 0;
    right: 0;
    height: 14px;
    width: 14px;
    background-color: #ff3860;
    border-radius: 50%;
    border: 3px solid #212529;
}

/* --- Contenuto e Sezioni --- */
main {
    flex-grow: 1;
}

.section {
    max-width: 960px;
    margin: 0 auto;
    background-color: rgba(0, 0, 0, 0.7);
    padding: 3rem;
    border-radius: 10px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
    animation: fadeIn 0.8s ease-in-out;
    opacity: 1;
    transition: opacity 0.5s ease-in-out;
}

.section h2 {
    font-family: 'Cinzel', serif;
    font-size: 2.5rem;
    color: var(--color-primary);
    text-align: center;
    margin-bottom: 2rem;
}

.centered-heading {
    text-align: center;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1;
}

.centered-heading h1 {
    font-family: 'Cinzel', serif;
    font-size: 4rem;
    color: white;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.7);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Stili specifici per lo shop */
.card-shop-circle {
    background-color: #262626 !important;
    border: 3px solid var(--color-primary) !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
    cursor: pointer;
    overflow: hidden;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 1.5rem;
    min-width: 220px; 
}

.card-shop-circle:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6);
    border-color: #a0522d !important;
}

.card-img-circle {
    width: 200px;
    height: 200px;
    object-fit: cover;
    border-radius: 50%;
    border: 2px solid var(--color-primary);
    margin-bottom: 1rem;
}

.card-shop-circle .card-body {
    padding: 0;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%; 
}

.card-shop-circle .card-title {
    font-family: 'Cinzel', serif;
    font-size: 1.5rem; 
    margin-bottom: 0.75rem;
    color: var(--color-text-light);
    line-height: 1.2;
    max-width: 100%;
    word-wrap: break-word;
}

.card-shop-circle .btn-primary {
    background-color: var(--color-primary);
    border-color: var(--color-primary);
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: bold;
    border-radius: 5px;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

.card-shop-circle .btn-primary:hover {
    background-color: #a0522d;
    border-color: #a0522d;
    transform: translateY(-2px);
}

/* --- Piè di pagina (Footer) --- */
.footer-custom {
    background-color: transparent;
    border-top: none;
    color: var(--color-text-light);
}

.social-links a {
    color: var(--color-text-light);
    font-size: 1.5rem;
    transition: color 0.3s ease, transform 0.3s ease;
}

.social-links a:hover {
    color: var(--color-primary);
    transform: scale(1.1);
}

/* --- PANNELLO ADMIN & USER --- */
/* Stili per i contenitori dei pannelli (comuni a entrambi) */
.admin-panel-container, .user-panel-container {
    max-width: 900px;
    width: 100%;
    background-color: rgba(35, 39, 42, 0.9);
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
    color: #fff;
    text-align: center;
}

/* Stili per il profilo (comuni a entrambi) */
.admin-profile, .user-profile {
    text-align: center;
    margin-bottom: 30px;
}

.admin-profile img, .user-profile img {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border: 3px solid var(--color-discord-blue);
    margin-bottom: 15px;
    box-shadow: 0 0 10px rgba(114, 137, 218, 0.5);
}

.admin-profile h2, .user-profile h2 {
    color: #fff;
    font-family: 'Cinzel', serif;
    margin-bottom: 5px;
}

.admin-profile p, .user-profile p {
    color: #b9bbbe;
}

/* Stili specifici per i pannelli */
.button-group {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 30px;
}

.btn-panel {
    padding: 15px 25px;
    background-color: var(--color-discord-blue);
    color: white;
    border: none;
    border-radius: 5px;
    text-decoration: none;
    font-size: 1.1em;
    transition: background-color 0.3s ease, transform 0.2s ease;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-panel i {
    margin-right: 10px;
}

.btn-panel:hover {
    background-color: #5b6eae;
    transform: translateY(-2px);
    color: white;
}

.btn-back-site {
    background-color: #faa61a;
    color: white;
    padding: 10px 20px;
    border-radius: 5px;
    text-decoration: none;
    font-size: 1em;
    transition: background-color 0.3s ease;
    display: inline-block;
    margin-top: 15px;
}

.btn-back-site:hover {
    background-color: #e09400;
    color: white;
}

.table-container {
    margin-top: 30px;
    overflow-x: auto;
}

.codes-table, .orders-table {
    width: 100%;
    color: #fff;
    background-color: #2c2f33;
    border-radius: 10px;
    overflow: hidden;
}

.codes-table th, .codes-table td,
.orders-table th, .orders-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #4f545c;
}

.codes-table th, .orders-table th {
    background-color: #4f545c;
    color: var(--color-discord-blue);
    font-weight: bold;
}

.codes-table tbody tr:hover, .orders-table tbody tr:hover {
    background-color: #36393f;
}

.status-redeemed {
    color: var(--color-discord-green);
    font-weight: bold;
}

.status-unredeemed {
    color: var(--color-discord-red);
    font-weight: bold;
}

.user-info {
    background-color: #2c2f33;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 30px;
    text-align: left;
}

.user-info p {
    margin-bottom: 5px;
    font-size: 1.1em;
}

.user-info strong {
    color: var(--color-discord-blue);
}

.form-control-custom {
    background-color: #2c2f33;
    color: #fff;
    border: 1px solid var(--color-discord-blue);
    transition: border-color 0.3s ease;
}

.form-control-custom:focus {
    background-color: #36393f;
    color: #fff;
    border-color: #99aab5;
    box-shadow: none;
}

.info-box {
    background-color: #2c2f33;
    padding: 20px;
    border-radius: 8px;
    text-align: left;
    margin-top: 20px;
}
/* Stile per evidenziare il nome utente del creatore */
.creator-status-name {
    color: #FFD700; /* Colore oro per un effetto "star" */
    font-weight: bold;
    text-shadow: 1px 1px 2px #000;
}