/* ============================================
   KOMPONENTY DODATKOWE
   ============================================ */

/* ============================================
   NAWIGACJA MOBILNA
   ============================================ */
@media (max-width: 768px) {
    .menu-toggle {
        display: block;
        background: none;
        border: none;
        color: var(--primary-gold);
        font-size: 1.5rem;
        cursor: pointer;
        padding: 0.5rem;
        transition: all 0.3s ease;
    }

    .menu-toggle.active {
        transform: rotate(90deg);
    }

    .site-nav {
        display: none;
        flex-direction: column;
        gap: 0;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: linear-gradient(180deg, var(--primary-brown) 0%, var(--primary-dark) 100%);
        border-top: 1px solid var(--border-gold);
        box-shadow: 0 8px 16px rgba(0, 0, 0, 0.9);
        z-index: 999;
    }

    .site-nav.show {
        display: flex;
    }

    .site-nav a {
        padding: 1rem;
        border-bottom: 1px solid rgba(212, 175, 55, 0.1);
        display: block;
    }
}

/* ============================================
   TOASTY NOTYFIKACJE
   ============================================ */
.toast {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: rgba(62, 39, 35, 0.95);
    border: 2px solid var(--primary-gold);
    color: var(--cream);
    padding: 1rem 1.5rem;
    border-radius: 3px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.7);
    z-index: 9999;
    animation: slideInRight 0.3s ease;
    max-width: 300px;
}

.toast.success {
    border-color: #4CAF50;
}

.toast.error {
    border-color: #f44336;
}

.toast.warning {
    border-color: var(--accent-gold);
}

@keyframes slideInRight {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* ============================================
   MODAL / POPUP
   ============================================ */
.modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    animation: fadeIn 0.3s ease;
}

.modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background-color: var(--primary-dark);
    border: 3px solid var(--primary-gold);
    padding: 2rem;
    border-radius: 3px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.9);
    animation: slideInUp 0.3s ease;
}

.modal-close {
    color: var(--primary-gold);
    float: right;
    font-size: 1.5rem;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
}

.modal-close:hover {
    color: var(--accent-gold);
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideInUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* ============================================
   BREADCRUMBS
   ============================================ */
.breadcrumbs {
    max-width: 1400px;
    margin: 1rem auto;
    padding: 0 2rem;
    font-size: 0.9rem;
}

.breadcrumbs a {
    color: var(--primary-gold);
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumbs a:hover {
    color: var(--accent-gold);
}

.breadcrumbs span {
    color: var(--light-brown);
    margin: 0 0.5rem;
}

.breadcrumbs .current {
    color: var(--cream);
}

/* ============================================
   PAGINATION
   ============================================ */
.pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin: 2rem 0;
    flex-wrap: wrap;
}

.pagination a,
.pagination span {
    display: inline-block;
    padding: 8px 12px;
    border: 1px solid var(--border-gold);
    color: var(--primary-gold);
    text-decoration: none;
    border-radius: 3px;
    transition: all 0.3s ease;
    font-size: 0.95rem;
}

.pagination a:hover {
    background-color: var(--primary-gold);
    color: var(--primary-dark);
}

.pagination .current {
    background-color: var(--primary-gold);
    color: var(--primary-dark);
    border-color: var(--primary-gold);
    font-weight: bold;
}

/* ============================================
   BADGE
   ============================================ */
.badge {
    display: inline-block;
    padding: 4px 8px;
    background-color: var(--primary-gold);
    color: var(--primary-dark);
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge.secondary {
    background-color: var(--secondary-brown);
    color: var(--primary-gold);
    border: 1px solid var(--primary-gold);
}

.badge.new {
    background-color: #4CAF50;
    color: white;
}

.badge.sale {
    background-color: #f44336;
    color: white;
}

/* ============================================
   TABELE
   ============================================ */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 1rem 0;
}

table th {
    background-color: rgba(62, 39, 35, 0.8);
    color: var(--primary-gold);
    padding: 1rem;
    text-align: left;
    font-weight: bold;
    border-bottom: 2px solid var(--border-gold);
}

table td {
    padding: 1rem;
    border-bottom: 1px solid var(--border-gold);
    color: var(--cream);
}

table tr:hover {
    background-color: rgba(62, 39, 35, 0.3);
}

table tr:last-child td {
    border-bottom: 2px solid var(--border-gold);
}

/* ============================================
   ALERT / INFO BLOKI
   ============================================ */
.alert {
    padding: 1rem 1.5rem;
    margin-bottom: 1rem;
    border: 2px solid transparent;
    border-radius: 3px;
    background-color: rgba(62, 39, 35, 0.5);
}

.alert-info {
    border-color: #2196F3;
    color: #2196F3;
    background-color: rgba(33, 150, 243, 0.1);
}

.alert-success {
    border-color: #4CAF50;
    color: #4CAF50;
    background-color: rgba(76, 175, 80, 0.1);
}

.alert-warning {
    border-color: var(--accent-gold);
    color: var(--accent-gold);
    background-color: rgba(255, 193, 7, 0.1);
}

.alert-error {
    border-color: #f44336;
    color: #f44336;
    background-color: rgba(244, 67, 54, 0.1);
}

/* ============================================
   LOADING SPINNER
   ============================================ */
.spinner {
    border: 4px solid rgba(212, 175, 55, 0.2);
    border-top: 4px solid var(--primary-gold);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    display: inline-block;
    margin: 1rem auto;
}

.spinner.small {
    width: 20px;
    height: 20px;
    border-width: 2px;
}

.spinner.large {
    width: 60px;
    height: 60px;
    border-width: 6px;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

/* ============================================
   CARD VARIANTS
   ============================================ */
.card.featured {
    border-width: 4px;
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.4);
}

.card.featured::before {
    background: radial-gradient(circle at 50% 0%, rgba(212, 175, 55, 0.2), transparent);
}

.card.dark {
    background: linear-gradient(135deg, rgba(30, 20, 18, 0.9) 0%, rgba(20, 12, 10, 1) 100%);
}

.card.minimal {
    border: 1px solid var(--border-gold);
    background: transparent;
}

/* ============================================
   GRID UTILITIES
   ============================================ */
.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

@media (max-width: 768px) {
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   SPACING UTILITIES
   ============================================ */
.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

.p-0 { padding: 0; }
.p-1 { padding: 0.5rem; }
.p-2 { padding: 1rem; }
.p-3 { padding: 1.5rem; }
.p-4 { padding: 2rem; }

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.text-gold { color: var(--primary-gold); }
.text-light { color: var(--cream); }
.text-muted { color: var(--light-brown); }

.bg-dark { background-color: var(--primary-dark); }
.bg-brown { background-color: var(--primary-brown); }

/* ============================================
   DISPLAY UTILITIES
   ============================================ */
.hidden {
    display: none !important;
}

.visible {
    display: block !important;
}

.inline-block {
    display: inline-block;
}

.flex {
    display: flex;
}

.flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
}

.flex-between {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* ============================================
   HOVER EFFECTS
   ============================================ */
.hover-gold:hover {
    color: var(--primary-gold);
}

.hover-lift:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 16px rgba(212, 175, 55, 0.2);
}

.hover-glow:hover {
    text-shadow: 0 0 10px rgba(212, 175, 55, 0.5);
}
