/* ============================================
   OSNOVNI STILOVI
   ============================================ */
html {
    font-size: 14px;
    position: relative;
    min-height: 100%;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

html, body {
    height: 100%;
    overflow-x: hidden;
}

body {
    background: linear-gradient(135deg, #232526 0%, #414345 100%);
    color: #fff;
    font-family: 'Segoe UI', Arial, sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    margin-bottom: 0;
}

@supports (min-height: 100dvh) {
    body {
        min-height: 100dvh;
    }
}

@media (max-width: 991.98px) {
    html {
        overscroll-behavior-y: none;
    }

    body {
        min-height: 100svh;
        overscroll-behavior-y: none;
        -webkit-overflow-scrolling: touch;
    }
}

@supports (min-height: 100dvh) {
    @media (max-width: 991.98px) {
        body {
            min-height: 100dvh;
        }
    }
}

main[role="main"] {
    flex: 1 0 auto;
}

/* Focus stilovi */
.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #ff3c00;
}

/* Remove 300ms tap delay on touch devices */
a, button, .btn, [role="button"], input, select, textarea, label {
    touch-action: manipulation;
}

@keyframes processingViewFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes processingCardEnter {
    from {
        opacity: 0;
        transform: translateY(8px) scale(0.99);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes processingProgress {
    0% { transform: translateX(-115%); }
    100% { transform: translateX(230%); }
}

@media (prefers-reduced-motion: reduce) {
    .submit-processing-view,
    .submit-processing-card,
    .submit-processing-progress span {
        animation: none;
    }
}

.filter-row {
    display: flex;
    gap: 1rem;
    align-items: flex-end;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.form-group {
    flex: 1;
    min-width: 180px;
}

.search-btn-group {
    display: flex;
    align-items: flex-end;
}

.search-btn {
    background: #ff4d1c;
    border: none;
    color: #fff;
    font-weight: bold;
    padding: 0.75rem 2rem;
    border-radius: 12px;
    font-size: 1.1rem;
    transition: background 0.2s;
}

.search-btn:hover {
    background: #e03e00;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

/* ============================================
   NOTIFICATION ALERTS
   ============================================ */
.notification-alert {
    position: fixed;
    top: 80px;
    right: 20px;
    z-index: 9999;
    min-width: 350px;
    max-width: 500px;
    animation: slideInRight 0.3s ease-out;
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
    border-radius: 12px;
    font-size: 1rem;
    border-left: 5px solid;
}

.notification-alert.alert-success {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    border-left-color: #155724;
    color: white;
}

.notification-alert.alert-danger {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    border-left-color: #721c24;
    color: white;
}

.notification-alert.alert-warning {
    background: linear-gradient(135deg, #ffc107 0%, #ff9800 100%);
    border-left-color: #856404;
    color: #212529;
}

.notification-alert.alert-info {
    background: linear-gradient(135deg, #17a2b8 0%, #138496 100%);
    border-left-color: #0c5460;
    color: white;
}

.notification-alert .btn-close {
    filter: brightness(0) invert(1);
}

.notification-alert.alert-warning .btn-close {
    filter: none;
}

@keyframes slideInRight {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@media (max-width: 768px) {
    .notification-alert {
        right: 10px;
        left: 10px;
        min-width: auto;
    }
}

/* Auto-dismiss after 5 seconds */
.notification-alert {
    animation: slideInRight 0.3s ease-out, fadeOut 0.5s ease-out 4.5s forwards;
}

@keyframes fadeOut {
    to {
        opacity: 0;
        transform: translateX(400px);
    }
}

/* ============================================
   NAVIGACIJA - Racing Style
   ============================================ */
.navbar {
    background: rgba(34,34,34,0.95);
    backdrop-filter: blur(10px);
    border-radius: 0 0 24px 24px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.4);
    padding: 0.7rem 2rem;
    transition: all 0.3s;
    border-bottom: 2px solid #ff3c00;
}

.navbar-nav {
    margin-left: 0 !important;
}

@media (min-width: 992px) {
    .navbar-nav {
        margin-left: 1.2rem !important;
    }
}

.navbar-brand {
    font-weight: 900;
    letter-spacing: 2px;
    color: #ff3c00 !important;
    display: flex;
    align-items: center;
    font-size: 2rem;
    text-shadow: 0 0 10px rgba(255,60,0,0.5);
}

    .navbar-brand i {
        font-size: 2.5rem;
        margin-right: 14px;
        color: #ff3c00;
        filter: drop-shadow(0 0 8px rgba(255,60,0,0.6));
    }

.nav-link, .dropdown-item {
    color: #fff !important;
    font-size: 1.15rem;
    font-weight: 500;
    transition: all 0.3s;
    border-radius: 12px;
    padding: 0.5rem 1rem;
    position: relative;
}

    .nav-link::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 50%;
        width: 0;
        height: 2px;
        background: linear-gradient(90deg, #ff3c00, #ffb300);
        transition: all 0.3s;
        transform: translateX(-50%);
    }

    .nav-link:hover::after {
        width: 80%;
    }

    .nav-link.active, .nav-link.home-active {
        color: #fff !important;
        background: linear-gradient(90deg, #ff3c00 0%, #ffb300 100%);
        box-shadow: 0 4px 15px rgba(255,60,0,0.4);
        font-weight: 700;
    }

    .nav-link:hover, .dropdown-item:hover {
        color: #ff3c00 !important;
        background: rgba(255,60,0,0.15);
        box-shadow: 0 2px 8px rgba(255,60,0,0.3);
    }

/* Admin Link Special Style */
.nav-link.admin-link {
    background: linear-gradient(135deg, rgba(220,53,69,0.2), rgba(220,53,69,0.1));
    border: 1px solid rgba(220,53,69,0.4);
    color: #dc3545 !important;
}

.nav-link.admin-link:hover {
    background: linear-gradient(135deg, #dc3545, #c82333);
    color: white !important;
    box-shadow: 0 4px 15px rgba(220,53,69,0.4);
}

.nav-link.admin-link i {
    color: #dc3545;
}

.nav-link.admin-link:hover i {
    color: white;
}

/* ============================================
   DROPDOWN MENU
   ============================================ */
.dropdown-menu {
    background: rgba(34,34,34,0.98);
    border: 1px solid rgba(255,60,0,0.3);
    box-shadow: 0 8px 32px rgba(0,0,0,0.5);
    border-radius: 16px;
    margin-top: 0.5rem;
    animation: dropdownFade 0.3s;
    max-height: calc(100vh - 80px);
    overflow-y: auto;
    overflow-x: hidden;
}

    .dropdown-menu::-webkit-scrollbar {
        width: 4px;
    }

    .dropdown-menu::-webkit-scrollbar-track {
        background: rgba(255,255,255,0.05);
        border-radius: 0 16px 16px 0;
    }

    .dropdown-menu::-webkit-scrollbar-thumb {
        background: rgba(255,60,0,0.5);
        border-radius: 4px;
    }

    .dropdown-menu::-webkit-scrollbar-thumb:hover {
        background: rgba(255,60,0,0.8);
    }

/* ============================================
   NAVBAR TOGGLER
   ============================================ */
.navbar-toggler {
    border: 2px solid #ff3c00;
    outline: none;
    background: transparent;
}

    .navbar-toggler:focus {
        box-shadow: 0 0 0 0.25rem rgba(255,60,0,0.25);
    }

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='%23ff3c00' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* ============================================
   BUTTON "PREDAJ OGLAS"
   ============================================ */
.navbar .btn-shop {
    background: linear-gradient(90deg, #ff3c00 0%, #ffb300 100%);
    color: #fff;
    font-weight: bold;
    border-radius: 30px;
    margin-left: 1rem;
    padding: 0.6rem 1.6rem;
    font-size: 1.1rem;
    box-shadow: 0 4px 15px rgba(255,60,0,0.4);
    border: none;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

    .navbar .btn-shop:hover {
        background: linear-gradient(90deg, #ffb300 0%, #ff3c00 100%);
        color: #fff;
        box-shadow: 0 6px 20px rgba(255,107,53,0.6);
        transform: translateY(-2px);
    }

/* ============================================
   AUTH BUTTONS (Uloguj se / Registruj se)
   ============================================ */
.btn-auth-login {
    background: rgba(40, 167, 69, 0.15);
    color: white;
    border: 2px solid #28a745;
    border-radius: 30px;
    padding: 0.6rem 1.6rem;
    font-weight: 700;
    transition: all 0.3s;
    box-shadow: 0 0 15px rgba(40, 167, 69, 0.3);
}

.btn-auth-login:hover {
    background: #28a745;
    border-color: #28a745;
    color: white;
    box-shadow: 0 0 25px rgba(40, 167, 69, 0.6);
    transform: translateY(-2px);
}

.btn-auth-register {
    background: rgba(220, 53, 69, 0.15);
    color: white;
    border: 2px solid #dc3545;
    border-radius: 30px;
    padding: 0.6rem 1.6rem;
    font-weight: 700;
    transition: all 0.3s;
    box-shadow: 0 0 15px rgba(220, 53, 69, 0.3);
}

.btn-auth-register:hover {
    background: #dc3545;
    border-color: #dc3545;
    color: white;
    box-shadow: 0 0 25px rgba(220, 53, 69, 0.6);
    transform: translateY(-2px);
}

/* ============================================
   AUTH BUTTONS (Uloguj se / Registruj se) - MOBILE
   ============================================ */
.auth-buttons-mobile {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    margin-top: 0.6rem;
    margin-bottom: 1.5rem;
}

.auth-buttons-mobile .btn-auth-login,
.auth-buttons-mobile .btn-auth-register {
    width: 100%;
    padding: 0.65rem 1rem;
    font-size: 1rem;
    border-radius: 25px;
}

/* Smanjeni razmak izme─æu auth dugmadi i "Predaj oglas" na mobilnom */
@media (max-width: 992px) {
    .navbar-collapse .auth-buttons-mobile + .btn-shop {
        margin-top: 0.4rem;
    }
    
    .navbar .btn-shop {
        padding: 0.54rem 1.44rem;
        font-size: 0.99rem;
        margin: 0 auto;
        display: block;
        width: 80%;
    }
}

/* ============================================
   FOOTER - Racing Style
   ============================================ */
.footer-custom {
    margin-top: auto;
}

.footer-content {
    background: rgba(34,34,34,0.95);
    border-radius: 24px 24px 0 0;
    box-shadow: 0 -4px 24px rgba(0,0,0,0.4);
    padding: 1.5rem 2rem;
    border-top: 2px solid #ff3c00;
}

@media (max-width: 991.98px) {
    .footer-content .row .order-1 {
        margin-bottom: 0.85rem;
    }

    .footer-content .row .order-2 {
        padding-top: 0.15rem;
    }
}

.footer-brand {
    font-weight: bold;
    color: #ff3c00;
    text-shadow: 0 0 10px rgba(255,60,0,0.5);
}

/* ============================================
   Motorcycle Index filter styles (moved from inline)
   ============================================ */
.filter-row {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: flex-end;
}
.filter-row .form-group {
    flex: 1 1 150px;
    min-width: 150px;
    display: flex;
    flex-direction: column;
}
.filter-row .form-group label {
    margin-bottom: .4rem;
}
.filter-row .form-control,
.filter-row select {
    height: 44px;
    padding: .5rem .75rem;
    box-sizing: border-box;
}
.search-btn,
.elegant-search-btn {
    height: 44px;
    padding: .5rem 1.25rem;
    border-radius: 10px;
    font-size: 1rem;
}
@media (max-width: 768px) {
    .filter-row {
        flex-direction: column;
        gap: 0.5rem;
        align-items: stretch;
    }
    .filter-row .form-group,
    .form-group.col-12 {
        width: 100%;
        min-width: unset;
    }
    .search-btn,
    .elegant-search-btn {
        width: 100%;
        height: 48px;
        border-radius: 8px;
    }
}
.filter-row .form-group.action {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.footer-link {
    text-decoration: none;
    color: #ff5a1f;
    transition: all 0.3s;
}

    .footer-link:hover {
        color: #ff3c00;
        text-shadow: 0 0 8px rgba(255,60,0,0.5);
    }

.btn-shop-footer {
    background: linear-gradient(90deg, #ff3c00 0%, #ffb300 100%);
    color: #fff;
    font-weight: bold;
    border-radius: 30px;
    padding: 0.4rem 1.2rem;
    font-size: 1rem;
    border: none;
    transition: all 0.3s;
    box-shadow: 0 2px 10px rgba(255,60,0,0.3);
}

    .btn-shop-footer:hover {
        background: linear-gradient(90deg, #ffb300 0%, #ff3c00 100%);
        color: #fff;
        transform: translateY(-2px);
        box-shadow: 0 4px 15px rgba(255,107,53,0.5);
    }

.footer-info,
.footer-nav {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.55rem 0.9rem;
}

.footer-nav {
    justify-content: flex-end;
}

.footer-info .ms-2,
.footer-email-link.ms-2,
.footer-nav .me-3 {
    margin-left: 0 !important;
    margin-right: 0 !important;
}

.footer-email-link {
    color: #ff5a1f;
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
}

.footer-email-link:hover {
    color: #ffb300;
    text-shadow: 0 0 8px rgba(255,60,0,0.5);
}

.footer-powered-text {
    display: inline-flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.25rem;
    max-width: 100%;
    line-height: 1.45;
}

@media (max-width: 991.98px) {
    .footer-content {
        padding: 1.45rem 1rem 1.6rem;
    }

    .footer-info,
    .footer-nav {
        justify-content: center;
        text-align: center;
    }

    .footer-nav {
        margin-bottom: 0.65rem;
    }

    .footer-info {
        margin-bottom: 0 !important;
    }
}

@media (max-width: 576px) {
    .footer-content {
        padding: 1.35rem 0.8rem 1.5rem;
        border-radius: 22px 22px 0 0;
    }

    .footer-info {
        flex-direction: column;
        gap: 0.35rem;
        font-size: 0.95rem;
    }

    .footer-email-link {
        order: 2;
    }

    .footer-copyright {
        order: 3;
    }

    .footer-nav {
        gap: 0.75rem 1rem;
        font-size: 1rem;
    }

    .footer-email-link {
        white-space: normal;
        overflow-wrap: anywhere;
        line-height: 1.35;
    }

    .btn-shop-footer {
        padding: 0.5rem 1.15rem;
    }

    .footer-powered {
        font-size: 0.86rem;
        padding-left: 0.25rem;
        padding-right: 0.25rem;
    }
}

/* ============================================
   HERO SEKCIJA - Racing Banner
   ============================================ */
.hero-section {
    margin-top: 0.5rem;
}

.hero-slide {
    min-height: 430px;
    display: flex;
    align-items: center;
    color: white;
    padding: 3rem 0;
    position: relative;
    overflow: hidden;
}

    .hero-slide::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: repeating-linear-gradient( 45deg, transparent, transparent 10px, rgba(255,60,0,0.05) 10px, rgba(255,60,0,0.05) 20px );
        pointer-events: none;
    }

.hero-title {
    font-size: 3rem;
    font-weight: 900;
    margin-bottom: 1rem;
    text-shadow: 0 0 20px rgba(0,0,0,0.5), 0 0 40px rgba(255,60,0,0.3);
    letter-spacing: 1px;
}

@media (max-width: 576px) {
    .hero-title {
        font-size: 1.8rem;
        letter-spacing: 0;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .hero-icon {
        font-size: 8rem;
    }
}

.hero-subtitle {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    text-shadow: 0 2px 10px rgba(0,0,0,0.5);
}

.hero-media-col {
    position: relative;
    z-index: 1;
    align-self: stretch;
    display: flex;
    align-items: stretch;
}

.hero-picture {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 320px;
    margin: 0;
}

.hero-image {
    width: 100%;
    height: 100%;
    min-height: 320px;
    object-fit: cover;
    border-radius: 24px;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.08);
}

.hero-icon {
    font-size: 15rem;
    opacity: 0.3;
    animation: pulse 3s infinite;
}

@media (max-width: 768px) {
    .hero-slide {
        min-height: 480px;
        padding: 1.4rem 1rem 3rem;
    }

    .hero-title {
        font-size: 2rem;
        letter-spacing: 0;
    }

    .hero-subtitle {
        font-size: 1rem;
        margin-bottom: 1.4rem;
    }

    .hero-picture {
        min-height: 240px;
        margin-top: 1.25rem;
    }

    .hero-image {
        min-height: 240px;
        border-radius: 18px;
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 0.3;
    }

    50% {
        transform: scale(1.05);
        opacity: 0.4;
    }
}

/* ============================================
   SEARCH FORMA - Racing Style
   ============================================ */
.search-box {
    background: rgba(28, 28, 28, 0.93);
    border-radius: 20px;
    box-shadow: 0 8px 40px rgba(255, 60, 0, 0.22), 0 4px 20px rgba(0, 0, 0, 0.55);
    border: 3px solid #ff3c00;
    max-width: 700px;
    margin: 0 auto;
    position: relative;
}

    .search-box::before {
        content: '';
        position: absolute;
        top: -2px;
        left: -2px;
        right: -2px;
        bottom: -2px;
        background: linear-gradient(45deg, #ff3c00, #ffb300, #ff3c00);
        border-radius: 20px;
        z-index: -1;
        opacity: 0;
        transition: opacity 0.3s;
    }

    .search-box:hover::before {
        opacity: 0.3;
    }

.search-header h4 {
    color: #ffffff;
    font-weight: 700;
    font-size: 1.5rem;
}

    .search-header h4 i {
        color: #ff3c00;
        text-shadow: 0 0 10px rgba(255,60,0,0.3);
    }

/* Form Labels */
.search-box .form-label {
    color: #ffb38a;
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
}

/* Custom Input & Select Stilovi */
.form-control-custom,
.form-select-custom {
    border: 1.5px solid rgba(255, 60, 0, 0.45);
    border-radius: 10px;
    padding: 0.7rem 1rem;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #ffffff;
    color: #222;
}

    .form-control-custom:focus,
    .form-select-custom:focus {
        border-color: #ff3c00;
        box-shadow: 0 0 0 0.25rem rgba(255,60,0,0.15), 0 0 15px rgba(255,60,0,0.2);
        background: #fff;
    }

    .form-control-custom::placeholder {
        color: #aaa;
        font-style: italic;
    }

/* Select Arrow Styling */
.form-select-custom {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23ff3c00' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2 5l6 6 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 16px 12px;
}

/* Dugmad Search */
.btn-search-primary {
    background: linear-gradient(135deg, #ff3c00 0%, #ff6b35 100%);
    color: white;
    font-weight: 700;
    font-size: 1.1rem;
    padding: 0.85rem 1.5rem;
    border: none;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(255,60,0,0.4);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

    .btn-search-primary::before {
        content: '';
        position: absolute;
        top: 50%;
        left: 50%;
        width: 0;
        height: 0;
        background: rgba(255,255,255,0.2);
        border-radius: 50%;
        transform: translate(-50%, -50%);
        transition: width 0.5s, height 0.5s;
    }

    .btn-search-primary:hover::before {
        width: 300px;
        height: 300px;
    }

    .btn-search-primary:hover {
        background: linear-gradient(135deg, #ff6b35 0%, #ff3c00 100%);
        transform: translateY(-2px);
        box-shadow: 0 6px 20px rgba(255,60,0,0.5);
        color: white;
    }

.btn-search-reset {
    background: linear-gradient(135deg, #6c757d 0%, #5a6268 100%);
    color: white;
    font-weight: 600;
    font-size: 1rem;
    padding: 0.85rem 1.5rem;
    border: none;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(108,117,125,0.2);
    transition: all 0.3s ease;
}

    .btn-search-reset:hover {
        background: linear-gradient(135deg, #5a6268 0%, #6c757d 100%);
        transform: translateY(-2px);
        box-shadow: 0 6px 20px rgba(108,117,125,0.3);
        color: white;
    }

/* ============================================
   SECTION HEADERS
   ============================================ */
.section-header h2 {
    font-size: 2rem;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 0 20px rgba(255,60,0,0.3);
}

.section-header .text-muted {
    color: #28a745 !important;
}

/* ============================================
   AD CARDS - Racing Theme
   ============================================ */

/* Link wrapper za kartice - bez underline */
.ad-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.ad-card-link:hover {
    text-decoration: none;
}

/* Svi elementi unutar linka - bez underline */
.ad-card-link * {
    text-decoration: none !important;
}

.ad-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 6px 20px rgba(255,60,0,0.35);
    transition: all 0.3s;
    height: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
}

    .ad-card::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        height: 3px;
        background: linear-gradient(90deg, #ff3c00, #ffb300);
        transform: scaleX(0);
        transition: transform 0.3s;
    }

    .ad-card:hover::before {
        transform: scaleX(1);
    }

    .ad-card:hover {
        transform: translateY(-8px);
        box-shadow: 0 12px 40px rgba(255,60,0,0.5);
    }

/* Premium card styling */
.premium-card {
    border: 2px solid #ff5a1f;
    box-shadow: 0 6px 24px rgba(255,90,31,0.45);
}

.premium-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #ff7a00;
    color: #fff;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0.22rem 0.65rem;
    border-radius: 4px;
    z-index: 2;
    letter-spacing: 0.04em;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    box-shadow: 0 2px 8px rgba(255,90,31,0.35);
}

.ad-image {
    position: relative;
    padding-top: 75%;
    overflow: hidden;
    background: #f0f0f0;
}

    .ad-image img {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        object-fit: cover;
        transition: transform 0.5s;
    }

.ad-card:hover .ad-image img {
    transform: scale(1.1) rotate(1deg);
}

.ad-body {
    padding: 0.8rem 1rem 1rem 1rem; /* Smanjen gornji padding sa 1rem na 0.8rem */
    flex: 1;
    display: flex;
    flex-direction: column;
}

.ad-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #333;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 1.4; /* Pove?an line-height da se ne zarezuju slova sa donjostranim dijelovima (g, j, p, q, y) */
}

.ad-manufacturer-model {
    font-size: 1.1rem;
    color: #ff3c00;
    font-weight: 700;
    margin-bottom: 0.8rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ad-manufacturer-model i {
    color: #666;
    font-size: 0.9rem;
    margin-right: 0.3rem;
}

.ad-manufacturer-model .text-muted {
    color: #111 !important;
    font-weight: 500;
}

.ad-details {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 0.8rem;
    flex: 1;
}

    .ad-details span {
        background: linear-gradient(135deg, #f5f5f5, #e8e8e8);
        padding: 0.2rem 0.6rem;
        border-radius: 6px;
    }

/* FOOTER SA CIJENOM I LOKACIJOM */
.ad-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    padding-top: 1rem;
}

.ad-location {
    font-size: 0.9rem;
    color: #666;
    display: flex;
    align-items: center;
}

.ad-location i {
    color: #ff3c00;
    margin-right: 0.3rem;
}

/* CIJENA U DESNOM DONJEM UGLU */
.ad-price {
    font-size: 1.6rem;
    font-weight: 800;
    color: #ff5a1f;
    text-align: right;
    white-space: nowrap;
}

/* IME PRODAVCA */
.ad-seller {
    font-size: 0.85rem;
    color: #666;
    margin-top: 0.8rem;
    padding-top: 0.8rem;
    border-top: 1px solid #f0f0f0;
    display: flex;
    align-items: center;
    gap: 0.35rem;
    min-height: 40px;
    flex-wrap: nowrap;
}

.ad-seller i.fa-user-circle {
    color: #ff3c00;
    font-size: 1rem;
    margin-right: 0.1rem;
    flex: 0 0 auto;
}

.ad-seller .seller-name {
    font-weight: 600;
    color: #333;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ad-seller .fa-check-circle {
    font-size: 0.85rem;
}

/* Verified Seller Badge */
.verified-seller-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #198754;
    font-size: 0.8rem;
    font-weight: 700;
    vertical-align: middle;
    background: linear-gradient(135deg, rgba(25, 135, 84, 0.17), rgba(40, 167, 69, 0.17));
    padding: 0.2rem 0.5rem;
    border-radius: 10px;
    border: 1px solid rgba(25, 135, 84, 0.58);
    margin-left: auto;
    flex-shrink: 0;
    white-space: nowrap;
    min-width: 138px;
    height: 26px;
    box-sizing: border-box;
}

.verified-seller-badge i {
    color: #198754;
}

.badge-placeholder {
    visibility: hidden;
}

/* ============================================
   VALIDACIJA FORMI - Form Validation Styles
   ============================================ */

/* Input validacija - Success */
.form-control.is-valid,
.form-select.is-valid {
    border-color: #28a745;
    background-image: none;
    box-shadow: inset 0 0 0 0.2rem rgba(40, 167, 69, 0.15);
}

.form-control.is-valid:focus,
.form-select.is-valid:focus {
    border-color: #28a745;
    box-shadow: inset 0 0 0 0.2rem rgba(40, 167, 69, 0.15), 0 0 0 0.25rem rgba(40, 167, 69, 0.25);
}

/* Input validacija - Error */
.form-control.is-invalid,
.form-select.is-invalid {
    border-color: #dc3545;
    background-image: none;
    box-shadow: inset 0 0 0 0.2rem rgba(220, 53, 69, 0.15);
}

.form-control.is-invalid:focus,
.form-select.is-invalid:focus {
    border-color: #dc3545;
    box-shadow: inset 0 0 0 0.2rem rgba(220, 53, 69, 0.15), 0 0 0 0.25rem rgba(220, 53, 69, 0.25);
}

/* Error messages */
.invalid-feedback {
    display: block;
    color: #dc3545;
    font-size: 0.875rem;
    margin-top: 0.25rem;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.invalid-feedback small {
    display: block;
    line-height: 1.4;
}

/* Character counters */
.char-counter {
    font-size: 0.85rem;
    color: #888;
}

.char-counter span {
    font-weight: 600;
    color: #ff3c00;
}

/* Form alerts */
.form-errors-alert {
    animation: slideDown 0.3s ease-out;
    border-radius: 12px;
    border: 2px solid #dc3545;
}

/* Loading spinner na form submit */
.spinner-border-sm {
    width: 1rem;
    height: 1rem;
    border-width: 0.2em;
}

/* ============================================
   AJAX PAGINACIJA - Pagination Styles
   ============================================ */

#paginationContainer {
    min-height: 300px;
}

.pagination-custom {
    gap: 0.5rem;
}

.pagination-custom .page-link {
    color: #ff3c00;
    border-radius: 8px;
    border: 2px solid rgba(255, 60, 0, 0.3);
    background: rgba(255, 60, 0, 0.05);
    transition: all 0.3s;
    font-weight: 500;
}

.pagination-custom .page-link:hover {
    background: rgba(255, 60, 0, 0.15);
    border-color: #ff3c00;
    transform: translateY(-2px);
}

.pagination-custom .page-item.active .page-link {
    background: linear-gradient(135deg, #ff3c00, #ff6b35);
    border-color: #ff3c00;
    box-shadow: 0 4px 12px rgba(255, 60, 0, 0.3);
}

/* Loading spinner za AJAX */
.ajax-loading {
    opacity: 0.6;
    pointer-events: none;
}

.ajax-loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.spinner-border {
    border-color: rgba(255, 60, 0, 0.3);
    border-right-color: #ff3c00;
}

/* ============================================
   RESPONSIVE VALIDACIJA
   ============================================ */

@media (max-width: 576px) {
    .invalid-feedback {
        font-size: 0.8rem;
    }

    .pagination-custom {
        justify-content: center;
    }

    .pagination-custom .page-link {
        padding: 0.5rem 0.75rem;
        font-size: 0.9rem;
    }
}

/* ============================================
   PRODUCT HERO SEKCIJA - Pove?ana Visina
   ============================================ */
.product-hero-section {
    margin-top: 0.5rem;
}

.product-hero-slide {
    min-height: 520px;
    display: flex;
    align-items: center;
    color: white;
    padding: 3.5rem 0;
    position: relative;
    overflow: hidden;
}

    .product-hero-slide::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: repeating-linear-gradient( 45deg, transparent, transparent 10px, rgba(255,60,0,0.05) 10px, rgba(255,60,0,0.05) 20px );
        pointer-events: none;
    }

.product-hero-content {
    padding: 2rem 0;
    position: relative;
    z-index: 1;
}

.product-hero-title {
    font-size: 3.5rem;
    font-weight: 900;
    margin-bottom: 1.5rem;
    text-shadow: 0 0 25px rgba(0,0,0,0.6), 0 0 50px rgba(255,60,0,0.4);
    letter-spacing: 1px;
}

.product-hero-subtitle {
    font-size: 1.4rem;
    margin-bottom: 2rem;
    text-shadow: 0 2px 15px rgba(0,0,0,0.6);
    line-height: 1.6;
}

.product-hero-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    margin-bottom: 2rem;
}

.product-hero-stats .stat-item {
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.product-hero-media-col {
    position: relative;
    z-index: 1;
    align-self: stretch;
    display: flex;
    align-items: stretch;
}

.product-hero-picture {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 380px;
    margin: 0;
}

.product-hero-image {
    width: 100%;
    height: 100%;
    min-height: 380px;
    object-fit: cover;
    border-radius: 24px;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.08);
}

.product-hero-icon {
    font-size: 15rem;
    opacity: 0.28;
    animation: pulse 3s infinite;
}

.hero-cta-btn {
    white-space: nowrap;
}

/* Responsive za Product Hero */
@media (max-width: 992px) {
    .product-hero-slide {
        min-height: 560px;
        padding: 2.5rem 0;
    }
    
    .product-hero-title {
        font-size: 2.5rem;
    }
    
    .product-hero-subtitle {
        font-size: 1.2rem;
    }
    
    .product-hero-picture {
        min-height: 300px;
    }
}

@media (max-width: 768px) {
    .product-hero-slide {
        min-height: 520px;
        padding: 1.4rem 1rem 3rem;
    }
    
    .product-hero-title {
        font-size: 2rem;
    }
    
    .product-hero-subtitle {
        font-size: 1.1rem;
    }
    
    .product-hero-stats {
        gap: 1rem;
        flex-direction: row;
    }

    .product-hero-image {
        min-height: 260px;
        border-radius: 18px;
    }

    .hero-cta-btn {
        width: 100%;
    }
}

@media (max-width: 576px) {
    .product-hero-slide {
        min-height: 500px;
        padding: 1.35rem 1rem 3rem;
    }

    .product-hero-title {
        font-size: 1.85rem;
    }

    .product-hero-subtitle {
        font-size: 1rem;
    }

    .product-hero-image {
        min-height: 240px;
    }
}

/* ============================================
   AD CARDS - Racing Theme - Responsive Adjustments
   ============================================ */

/* Tablet and Mobile adjustments */
@media (max-width: 768px) {
    .ad-card {
        height: 100%;
    }

    .ad-body {
        padding: 0.7rem 0.8rem;
        display: flex;
        flex-direction: column;
        height: 100%;
    }

    .ad-title,
    .ad-manufacturer-model {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .ad-title {
        font-size: 0.95rem;
        min-height: 1.35em;
    }

    .ad-manufacturer-model {
        font-size: 0.95rem;
        min-height: 1.35em;
    }

    .ad-details {
        gap: 0.35rem;
        min-height: 46px;
    }

    .ad-details span {
        font-size: 0.75rem;
        padding: 0.15rem 0.45rem;
    }

    .ad-footer {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
        padding-top: 0.6rem;
        min-height: 52px;
    }

    .ad-location {
        width: 100%;
        font-size: 0.85rem;
    }

    .ad-price {
        width: 100%;
        text-align: left;
        font-size: 1.25rem;
    }

    .ad-seller {
        display: grid;
        grid-template-columns: auto minmax(0, 1fr) auto;
        align-items: center;
        column-gap: 0.25rem;
        min-height: 34px;
        flex-wrap: unset;
    }

    .ad-seller .seller-name {
        min-width: 0;
        max-width: none;
    }

    .verified-seller-badge {
        min-width: 0;
        width: auto;
        max-width: 100%;
        height: 22px;
        padding: 0.1rem 0.4rem;
        font-size: 0.6rem;
        margin-left: 0;
        justify-self: end;
    }
}

/* Mobile specific adjustments */
@media (max-width: 576px) {
    .ad-card {
        height: 100%;
        display: flex;
        flex-direction: column;
    }

    .ad-image {
        padding-top: 70%;
    }

    .ad-body {
        padding: 0.7rem 0.8rem 0.85rem 0.8rem;
        display: flex;
        flex-direction: column;
        flex: 1;
    }

    .ad-title {
        font-size: 0.95rem;
        line-height: 1.35;
        white-space: normal;
        display: block;
        overflow: hidden;
        text-overflow: ellipsis;
        min-height: 2.6em;
        max-height: 2.7em;
    }

    .ad-manufacturer-model {
        font-size: 0.95rem;
        white-space: normal;
        line-height: 1.25;
        min-height: 2.4em;
    }

    .ad-details {
        gap: 0.35rem;
        margin-bottom: 0.65rem;
        min-height: 3.1em;
    }

    .ad-details span {
        font-size: 0.75rem;
        padding: 0.15rem 0.45rem;
    }

    .ad-footer {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.35rem;
        padding-top: 0.75rem;
        min-height: 3.6em;
    }

    .ad-location {
        width: 100%;
        font-size: 0.85rem;
    }

    .ad-price {
        width: 100%;
        text-align: left;
        font-size: 1.35rem;
    }

    .ad-seller {
        display: grid;
        grid-template-columns: auto minmax(0, 1fr) auto;
        align-items: center;
        column-gap: 0.25rem;
        min-height: 34px;
        flex-wrap: unset;
        row-gap: 0;
    }

    .ad-seller .seller-name {
        min-width: 0;
        max-width: none;
    }

    .verified-seller-badge {
        min-width: 0;
        width: fit-content;
        max-width: 104px;
        height: 20px;
        padding: 0.05rem 0.25rem;
        font-size: 0.5rem;
        border-radius: 9px;
        margin-left: 0;
        justify-self: end;
        overflow: hidden;
        text-overflow: ellipsis;
    }
}

/* ============================================
   LIGHTBOX - Image Modal
   ============================================ */
.lightbox-modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.lightbox-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Dugmad su sada relativna prema modalu (100vw ├ù 100vh), ne prema content divi */
.lightbox-close {
    position: absolute;
    top: 15px;
    right: 15px;
    color: white;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    background: rgba(255, 60, 0, 0.8);
    border: none;
    border-radius: 50%;
    width: 46px;
    height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    line-height: 1;
    transition: all 0.2s;
    z-index: 10002;
}

.lightbox-close:hover {
    background: #ff3c00;
    transform: scale(1.1);
}

.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: white;
    font-size: 26px;
    font-weight: bold;
    cursor: pointer;
    background: rgba(255, 60, 0, 0.7);
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    z-index: 10002;
    flex-shrink: 0;
}

.lightbox-prev:hover,
.lightbox-next:hover {
    background: #ff3c00;
    transform: translateY(-50%) scale(1.1);
}

.lightbox-prev {
    left: 20px;
}

.lightbox-next {
    right: 20px;
}

.lightbox-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    /* Ostavlja prostor za strelice (50px + 20px margin s obje strane) */
    max-width: calc(100vw - 160px);
    max-height: 95vh;
    animation: zoomIn 0.25s ease-out;
}

@keyframes zoomIn {
    from { transform: scale(0.85); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.lightbox-img-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.lightbox-image {
    max-width: 100%;
    max-height: 82vh;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 10px;
    box-shadow: 0 0 30px rgba(255, 60, 0, 0.4);
    transition: opacity 0.2s ease;
}

.lightbox-counter {
    margin-top: 12px;
    color: white;
    font-size: 14px;
    font-weight: 600;
    background: rgba(255, 60, 0, 0.7);
    padding: 6px 16px;
    border-radius: 20px;
}

/* Desktop - slike klikabilne */
.detail-main-image {
    cursor: pointer;
    transition: transform 0.3s;
}

.detail-main-image:hover {
    transform: scale(1.02);
    box-shadow: 0 8px 25px rgba(255, 60, 0, 0.4);
}

.thumbnail-item {
    cursor: pointer;
}

/* Thumbnail grid - fixed 4-column layout */
.thumbnail-gallery {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin-top: 8px;
}

.thumbnail-gallery .thumbnail-item img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 4px;
}

/* Tablet */
@media (max-width: 768px) {
    .lightbox-content {
        max-width: calc(100vw - 110px);
    }

    .lightbox-prev,
    .lightbox-next {
        width: 42px;
        height: 42px;
        font-size: 20px;
    }

    .lightbox-prev { left: 10px; }
    .lightbox-next { right: 10px; }

    .lightbox-close {
        top: 10px;
        right: 10px;
        width: 42px;
        height: 42px;
        font-size: 22px;
    }
}

/* Mobile */
@media (max-width: 576px) {
    .lightbox-content {
        max-width: 100vw;
        padding: 0 54px; /* prostor za strelice */
    }

    .lightbox-image {
        max-height: 70vh;
        border-radius: 6px;
    }

    .lightbox-prev,
    .lightbox-next {
        width: 38px;
        height: 38px;
        font-size: 16px;
    }

    .lightbox-prev { left: 6px; }
    .lightbox-next { right: 6px; }

    .lightbox-close {
        top: 8px;
        right: 8px;
        width: 38px;
        height: 38px;
        font-size: 20px;
    }

    .lightbox-counter {
        margin-top: 8px;
        font-size: 12px;
        padding: 4px 12px;
    }
}

/* Smanjenje desktop CTA dugmadi u navbaru (~10%) */
@media (min-width: 992px) {
    .navbar .auth-buttons .btn-auth-login,
    .navbar .auth-buttons .btn-auth-register,
    .navbar .btn-shop.d-none.d-lg-flex {
        padding: 0.54rem 1.44rem;
        font-size: 0.99rem;
    }
}

/* Hamburger: prika┼╛i X kada je meni otvoren */
.navbar-toggler[aria-expanded="true"] .navbar-toggler-icon {
    background-image: none;
    position: relative;
}

.navbar-toggler[aria-expanded="true"] .navbar-toggler-icon::before,
.navbar-toggler[aria-expanded="true"] .navbar-toggler-icon::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    width: 18px;
    height: 2.8px;
    background: #ff3c00;
    border-radius: 2px;
    transform-origin: center;
}

.navbar-toggler[aria-expanded="true"] .navbar-toggler-icon::before {
    transform: translate(-50%, -50%) rotate(45deg);
}

.navbar-toggler[aria-expanded="true"] .navbar-toggler-icon::after {
    transform: translate(-50%, -50%) rotate(-45deg);
}

/* Footer powered by */
.footer-powered {
    margin-top: 0.9rem;
    padding-top: 0.85rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.72);
}

.footer-powered-link {
    color: #ff5a1f;
    text-decoration: none;
    font-weight: 600;
}

.footer-powered-link:hover {
    color: #ff7a1f;
    text-shadow: 0 0 8px rgba(255, 90, 31, 0.4);
}

/* ============================================
   FOOTER SOCIAL ICONS
   ============================================ */
.footer-social-icons {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin-top: 0.5rem;
}

.footer-social-icon {
    color: #ff3c00;
    font-size: 1.4rem;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1.5px solid rgba(255, 60, 0, 0.3);
    background: rgba(255, 60, 0, 0.08);
}

.footer-social-icon:hover {
    color: #28a745;
    border-color: #28a745;
    background: rgba(40, 167, 69, 0.12);
    box-shadow: 0 0 14px rgba(40, 167, 69, 0.5);
    transform: translateY(-3px);
}

@media (max-width: 768px) {
    .footer-social-icons {
        gap: 1.2rem;
        margin-top: 0.6rem;
    }

    .footer-social-icon {
        font-size: 1.6rem;
        width: 44px;
        height: 44px;
    }
}

/* ============================================
   MOBILE NAVBAR STABILITY
   ============================================ */
@media (max-width: 991.98px) {
    .navbar.sticky-top {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        z-index: 1050;
    }

    body {
        padding-top: 88px;
    }

    .navbar-collapse {
        max-height: calc(100vh - 96px);
        overflow-y: auto;
        overscroll-behavior: contain;
        -webkit-overflow-scrolling: touch;
    }
}

@supports (height: 100dvh) {
    @media (max-width: 991.98px) {
        .navbar-collapse {
            max-height: calc(100dvh - 96px);
        }
    }
}

/* Hero carousel rounding and spacing */
#heroCarousel {
    border-radius: 18px;
    overflow: hidden;
}

/* Mobile carousel paint/compositing stability (prevents background flicker on slide change) */
#heroCarousel .carousel-inner,
#productHeroCarousel .carousel-inner {
    background: #232526;
    transform: translateZ(0);
    -webkit-transform: translateZ(0);
}

#heroCarousel .carousel-item,
#productHeroCarousel .carousel-item,
.hero-slide,
.product-hero-slide {
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    transform: translateZ(0);
    -webkit-transform: translateZ(0);
    will-change: transform, opacity;
}

@media (max-width: 991.98px) {
    .hero-section {
        margin-top: 0.35rem;
    }

    #heroCarousel {
        border-radius: 14px;
    }
}

/* Product hero carousel rounding and spacing */
#productHeroCarousel {
    border-radius: 18px;
    overflow: hidden;
}

@media (max-width: 992px) {
    .product-hero-section {
        margin-top: 0.35rem;
    }

    #productHeroCarousel {
        border-radius: 14px;
    }
}

.thumbnail-item {
    cursor: pointer;
}

/* Thumbnail grid - fixed 4-column layout */
.thumbnail-gallery {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin-top: 8px;
}

.thumbnail-gallery .thumbnail-item img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 4px;
}

/* ============================================
   Motorcycle Index filter styles (moved from inline)
   ============================================ */
.filter-form {
    background: rgba(30, 30, 30, 0.75);
    border: 2px solid #ff3c00;
    border-radius: 16px;
    padding: 1.25rem 1.5rem 1rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 24px rgba(255, 60, 0, 0.18), 0 2px 12px rgba(0, 0, 0, 0.35);
    backdrop-filter: blur(6px);
    transition: box-shadow 0.3s, border-color 0.3s;
}

.filter-form:hover {
    border-color: #ff6b35;
    box-shadow: 0 6px 32px rgba(255, 60, 0, 0.28), 0 2px 16px rgba(0, 0, 0, 0.4);
}

.filter-form .filter-row .form-group label {
    color: #ffb38a;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.03em;
}

.filter-form .form-control,
.filter-form select {
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 60, 0, 0.35);
    color: #fff;
    border-radius: 8px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.filter-form .form-control::placeholder {
    color: rgba(255, 255, 255, 0.35);
}

.filter-form .form-control:focus,
.filter-form select:focus {
    background: rgba(255, 255, 255, 0.1);
    border-color: #ff3c00;
    box-shadow: 0 0 0 3px rgba(255, 60, 0, 0.2);
    color: #fff;
    outline: none;
}

.filter-form select option {
    background: #222;
    color: #fff;
}

.filter-row {
    display: flex;
    gap: 1rem;
    align-items: flex-end;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.form-group {
    flex: 1;
    min-width: 180px;
}

.search-btn-group {
    display: flex;
    align-items: flex-end;
}

.search-btn {
    background: #ff4d1c;
    border: none;
    color: #fff;
    font-weight: bold;
    padding: 0.75rem 2rem;
    border-radius: 12px;
    font-size: 1.1rem;
    transition: background 0.2s;
}

.search-btn:hover {
    background: #e03e00;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

/* ============================================
   NOTIFICATION ALERTS
   ============================================ */
.notification-alert {
    position: fixed;
    top: 80px;
    right: 20px;
    z-index: 9999;
    min-width: 350px;
    max-width: 500px;
    animation: slideInRight 0.3s ease-out;
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
    border-radius: 12px;
    font-size: 1rem;
    border-left: 5px solid;
}

.notification-alert.alert-success {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    border-left-color: #155724;
    color: white;
}

.notification-alert.alert-danger {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    border-left-color: #721c24;
    color: white;
}

.notification-alert.alert-warning {
    background: linear-gradient(135deg, #ffc107 0%, #ff9800 100%);
    border-left-color: #856404;
    color: #212529;
}

.notification-alert.alert-info {
    background: linear-gradient(135deg, #17a2b8 0%, #138496 100%);
    border-left-color: #0c5460;
    color: white;
}

.notification-alert .btn-close {
    filter: brightness(0) invert(1);
}

.notification-alert.alert-warning .btn-close {
    filter: none;
}

@keyframes slideInRight {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@media (max-width: 768px) {
    .notification-alert {
        right: 10px;
        left: 10px;
        min-width: auto;
    }
}

/* Auto-dismiss after 5 seconds */
.notification-alert {
    animation: slideInRight 0.3s ease-out, fadeOut 0.5s ease-out 4.5s forwards;
}

@keyframes fadeOut {
    to {
        opacity: 0;
        transform: translateX(400px);
    }
}

/* ============================================
   NAVIGACIJA - Racing Style
   ============================================ */
.navbar {
    background: rgba(34,34,34,0.95);
    backdrop-filter: blur(10px);
    border-radius: 0 0 24px 24px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.4);
    padding: 0.7rem 2rem;
    transition: all 0.3s;
    border-bottom: 2px solid #ff3c00;
}

.navbar-nav {
    margin-left: 0 !important;
}

@media (min-width: 992px) {
    .navbar-nav {
        margin-left: 1.2rem !important;
    }
}

.navbar-brand {
    font-weight: 900;
    letter-spacing: 2px;
    color: #ff3c00 !important;
    display: flex;
    align-items: center;
    font-size: 2rem;
    text-shadow: 0 0 10px rgba(255,60,0,0.5);
}

    .navbar-brand i {
        font-size: 2.5rem;
        margin-right: 14px;
        color: #ff3c00;
        filter: drop-shadow(0 0 8px rgba(255,60,0,0.6));
    }

.nav-link, .dropdown-item {
    color: #fff !important;
    font-size: 1.15rem;
    font-weight: 500;
    transition: all 0.3s;
    border-radius: 12px;
    padding: 0.5rem 1rem;
    position: relative;
}

    .nav-link::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 50%;
        width: 0;
        height: 2px;
        background: linear-gradient(90deg, #ff3c00, #ffb300);
        transition: all 0.3s;
        transform: translateX(-50%);
    }

    .nav-link:hover::after {
        width: 80%;
    }

    .nav-link.active, .nav-link.home-active {
        color: #fff !important;
        background: linear-gradient(90deg, #ff3c00 0%, #ffb300 100%);
        box-shadow: 0 4px 15px rgba(255,60,0,0.4);
        font-weight: 700;
    }

    .nav-link:hover, .dropdown-item:hover {
        color: #ff3c00 !important;
        background: rgba(255,60,0,0.15);
        box-shadow: 0 2px 8px rgba(255,60,0,0.3);
    }

/* Admin Link Special Style */
.nav-link.admin-link {
    background: linear-gradient(135deg, rgba(220,53,69,0.2), rgba(220,53,69,0.1));
    border: 1px solid rgba(220,53,69,0.4);
    color: #dc3545 !important;
}

.nav-link.admin-link:hover {
    background: linear-gradient(135deg, #dc3545, #c82333);
    color: white !important;
    box-shadow: 0 4px 15px rgba(220,53,69,0.4);
}

.nav-link.admin-link i {
    color: #dc3545;
}

.nav-link.admin-link:hover i {
    color: white;
}

/* ============================================
   DROPDOWN MENU
   ============================================ */
.dropdown-menu {
    background: rgba(34,34,34,0.98);
    border: 1px solid rgba(255,60,0,0.3);
    box-shadow: 0 8px 32px rgba(0,0,0,0.5);
    border-radius: 16px;
    margin-top: 0.5rem;
    animation: dropdownFade 0.3s;
    max-height: calc(100vh - 80px);
    overflow-y: auto;
    overflow-x: hidden;
}

    .dropdown-menu::-webkit-scrollbar {
        width: 4px;
    }

    .dropdown-menu::-webkit-scrollbar-track {
        background: rgba(255,255,255,0.05);
        border-radius: 0 16px 16px 0;
    }

    .dropdown-menu::-webkit-scrollbar-thumb {
        background: rgba(255,60,0,0.5);
        border-radius: 4px;
    }

    .dropdown-menu::-webkit-scrollbar-thumb:hover {
        background: rgba(255,60,0,0.8);
    }

/* ============================================
   NAVBAR TOGGLER
   ============================================ */
.navbar-toggler {
    border: 2px solid #ff3c00;
    outline: none;
    background: transparent;
}

    .navbar-toggler:focus {
        box-shadow: 0 0 0 0.25rem rgba(255,60,0,0.25);
    }

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='%23ff3c00' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* ============================================
   BUTTON "PREDAJ OGLAS"
   ============================================ */
.navbar .btn-shop {
    background: linear-gradient(90deg, #ff3c00 0%, #ffb300 100%);
    color: #fff;
    font-weight: bold;
    border-radius: 30px;
    margin-left: 1rem;
    padding: 0.6rem 1.6rem;
    font-size: 1.1rem;
    box-shadow: 0 4px 15px rgba(255,60,0,0.4);
    border: none;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

    .navbar .btn-shop:hover {
        background: linear-gradient(90deg, #ffb300 0%, #ff3c00 100%);
        color: #fff;
        box-shadow: 0 6px 20px rgba(255,107,53,0.6);
        transform: translateY(-2px);
    }

/* ============================================
   AUTH BUTTONS (Uloguj se / Registruj se)
   ============================================ */
.btn-auth-login {
    background: rgba(40, 167, 69, 0.15);
    color: white;
    border: 2px solid #28a745;
    border-radius: 30px;
    padding: 0.6rem 1.6rem;
    font-weight: 700;
    transition: all 0.3s;
    box-shadow: 0 0 15px rgba(40, 167, 69, 0.3);
}

.btn-auth-login:hover {
    background: #28a745;
    border-color: #28a745;
    color: white;
    box-shadow: 0 0 25px rgba(40, 167, 69, 0.6);
    transform: translateY(-2px);
}

.btn-auth-register {
    background: rgba(220, 53, 69, 0.15);
    color: white;
    border: 2px solid #dc3545;
    border-radius: 30px;
    padding: 0.6rem 1.6rem;
    font-weight: 700;
    transition: all 0.3s;
    box-shadow: 0 0 15px rgba(220, 53, 69, 0.3);
}

.btn-auth-register:hover {
    background: #dc3545;
    border-color: #dc3545;
    color: white;
    box-shadow: 0 0 25px rgba(220, 53, 69, 0.6);
    transform: translateY(-2px);
}

/* ============================================
   AUTH BUTTONS (Uloguj se / Registruj se) - MOBILE
   ============================================ */
.auth-buttons-mobile {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    margin-top: 0.6rem;
    margin-bottom: 1.5rem;
}

.auth-buttons-mobile .btn-auth-login,
.auth-buttons-mobile .btn-auth-register {
    width: 100%;
    padding: 0.65rem 1rem;
    font-size: 1rem;
    border-radius: 25px;
}

/* Smanjeni razmak izme─æu auth dugmadi i "Predaj oglas" na mobilnom */
@media (max-width: 992px) {
    .navbar-collapse .auth-buttons-mobile + .btn-shop {
        margin-top: 0.4rem;
    }
    
    .navbar .btn-shop {
        padding: 0.54rem 1.44rem;
        font-size: 0.99rem;
        margin: 0 auto;
        display: block;
        width: 80%;
    }
}

/* ============================================
   FOOTER - Racing Style
   ============================================ */
.footer-custom {
    margin-top: auto;
}

.footer-content {
    background: rgba(34,34,34,0.95);
    border-radius: 24px 24px 0 0;
    box-shadow: 0 -4px 24px rgba(0,0,0,0.4);
    padding: 1.5rem 2rem;
    border-top: 2px solid #ff3c00;
}

@media (max-width: 991.98px) {
    .footer-content .row .order-1 {
        margin-bottom: 0.85rem;
    }

    .footer-content .row .order-2 {
        padding-top: 0.15rem;
    }
}

.footer-brand {
    font-weight: bold;
    color: #ff3c00;
    text-shadow: 0 0 10px rgba(255,60,0,0.5);
}

/* ============================================
   Motorcycle Index filter styles (moved from inline)
   ============================================ */
.filter-form {
    background: rgba(30, 30, 30, 0.75);
    border: 2px solid #ff3c00;
    border-radius: 16px;
    padding: 1.25rem 1.5rem 1rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 24px rgba(255, 60, 0, 0.18), 0 2px 12px rgba(0, 0, 0, 0.35);
    backdrop-filter: blur(6px);
    transition: box-shadow 0.3s, border-color 0.3s;
}

.filter-form:hover {
    border-color: #ff6b35;
    box-shadow: 0 6px 32px rgba(255, 60, 0, 0.28), 0 2px 16px rgba(0, 0, 0, 0.4);
}

.filter-form .filter-row .form-group label {
    color: #ffb38a;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.03em;
}

.filter-form .form-control,
.filter-form select {
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 60, 0, 0.35);
    color: #fff;
    border-radius: 8px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.filter-form .form-control::placeholder {
    color: rgba(255, 255, 255, 0.35);
}

.filter-form .form-control:focus,
.filter-form select:focus {
    background: rgba(255, 255, 255, 0.1);
    border-color: #ff3c00;
    box-shadow: 0 0 0 3px rgba(255, 60, 0, 0.2);
    color: #fff;
    outline: none;
}

.filter-form select option {
    background: #222;
    color: #fff;
}

.filter-row {
    display: flex;
    gap: 1rem;
    align-items: flex-end;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.form-group {
    flex: 1;
    min-width: 180px;
}

.search-btn-group {
    display: flex;
    align-items: flex-end;
}

.search-btn {
    background: #ff4d1c;
    border: none;
    color: #fff;
    font-weight: bold;
    padding: 0.75rem 2rem;
    border-radius: 12px;
    font-size: 1.1rem;
    transition: background 0.2s;
}

.search-btn:hover {
    background: #e03e00;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

/* ============================================
   NOTIFICATION ALERTS
   ============================================ */
.notification-alert {
    position: fixed;
    top: 80px;
    right: 20px;
    z-index: 9999;
    min-width: 350px;
    max-width: 500px;
    animation: slideInRight 0.3s ease-out;
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
    border-radius: 12px;
    font-size: 1rem;
    border-left: 5px solid;
}

.notification-alert.alert-success {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    border-left-color: #155724;
    color: white;
}

.notification-alert.alert-danger {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    border-left-color: #721c24;
    color: white;
}

.notification-alert.alert-warning {
    background: linear-gradient(135deg, #ffc107 0%, #ff9800 100%);
    border-left-color: #856404;
    color: #212529;
}

.notification-alert.alert-info {
    background: linear-gradient(135deg, #17a2b8 0%, #138496 100%);
    border-left-color: #0c5460;
    color: white;
}

.notification-alert .btn-close {
    filter: brightness(0) invert(1);
}

.notification-alert.alert-warning .btn-close {
    filter: none;
}

@keyframes slideInRight {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@media (max-width: 768px) {
    .notification-alert {
        right: 10px;
        left: 10px;
        min-width: auto;
    }
}

/* Auto-dismiss after 5 seconds */
.notification-alert {
    animation: slideInRight 0.3s ease-out, fadeOut 0.5s ease-out 4.5s forwards;
}

@keyframes fadeOut {
    to {
        opacity: 0;
        transform: translateX(400px);
    }
}

/* ============================================
   NAVIGACIJA - Racing Style
   ============================================ */
.navbar {
    background: rgba(34,34,34,0.95);
    backdrop-filter: blur(10px);
    border-radius: 0 0 24px 24px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.4);
    padding: 0.7rem 2rem;
    transition: all 0.3s;
    border-bottom: 2px solid #ff3c00;
}

.navbar-nav {
    margin-left: 0 !important;
}

@media (min-width: 992px) {
    .navbar-nav {
        margin-left: 1.2rem !important;
    }
}

.navbar-brand {
    font-weight: 900;
    letter-spacing: 2px;
    color: #ff3c00 !important;
    display: flex;
    align-items: center;
    font-size: 2rem;
    text-shadow: 0 0 10px rgba(255,60,0,0.5);
}

    .navbar-brand i {
        font-size: 2.5rem;
        margin-right: 14px;
        color: #ff3c00;
        filter: drop-shadow(0 0 8px rgba(255,60,0,0.6));
    }

.nav-link, .dropdown-item {
    color: #fff !important;
    font-size: 1.15rem;
    font-weight: 500;
    transition: all 0.3s;
    border-radius: 12px;
    padding: 0.5rem 1rem;
    position: relative;
}

    .nav-link::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 50%;
        width: 0;
        height: 2px;
        background: linear-gradient(90deg, #ff3c00, #ffb300);
        transition: all 0.3s;
        transform: translateX(-50%);
    }

    .nav-link:hover::after {
        width: 80%;
    }

    .nav-link.active, .nav-link.home-active {
        color: #fff !important;
        background: linear-gradient(90deg, #ff3c00 0%, #ffb300 100%);
        box-shadow: 0 4px 15px rgba(255,60,0,0.4);
        font-weight: 700;
    }

    .nav-link:hover, .dropdown-item:hover {
        color: #ff3c00 !important;
        background: rgba(255,60,0,0.15);
        box-shadow: 0 2px 8px rgba(255,60,0,0.3);
    }

/* Admin Link Special Style */
.nav-link.admin-link {
    background: linear-gradient(135deg, rgba(220,53,69,0.2), rgba(220,53,69,0.1));
    border: 1px solid rgba(220,53,69,0.4);
    color: #dc3545 !important;
}

.nav-link.admin-link:hover {
    background: linear-gradient(135deg, #dc3545, #c82333);
    color: white !important;
    box-shadow: 0 4px 15px rgba(220,53,69,0.4);
}

.nav-link.admin-link i {
    color: #dc3545;
}

.nav-link.admin-link:hover i {
    color: white;
}

/* ============================================
   DROPDOWN MENU
   ============================================ */
.dropdown-menu {
    background: rgba(34,34,34,0.98);
    border: 1px solid rgba(255,60,0,0.3);
    box-shadow: 0 8px 32px rgba(0,0,0,0.5);
    border-radius: 16px;
    margin-top: 0.5rem;
    animation: dropdownFade 0.3s;
    max-height: calc(100vh - 80px);
    overflow-y: auto;
    overflow-x: hidden;
}

    .dropdown-menu::-webkit-scrollbar {
        width: 4px;
    }

    .dropdown-menu::-webkit-scrollbar-track {
        background: rgba(255,255,255,0.05);
        border-radius: 0 16px 16px 0;
    }

    .dropdown-menu::-webkit-scrollbar-thumb {
        background: rgba(255,60,0,0.5);
        border-radius: 4px;
    }

    .dropdown-menu::-webkit-scrollbar-thumb:hover {
        background: rgba(255,60,0,0.8);
    }

/* ============================================
   NAVBAR TOGGLER
   ============================================ */
.navbar-toggler {
    border: 2px solid #ff3c00;
    outline: none;
    background: transparent;
}

    .navbar-toggler:focus {
        box-shadow: 0 0 0 0.25rem rgba(255,60,0,0.25);
    }

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='%23ff3c00' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* ============================================
   BUTTON "PREDAJ OGLAS"
   ============================================ */
.navbar .btn-shop {
    background: linear-gradient(90deg, #ff3c00 0%, #ffb300 100%);
    color: #fff;
    font-weight: bold;
    border-radius: 30px;
    margin-left: 1rem;
    padding: 0.6rem 1.6rem;
    font-size: 1.1rem;
    box-shadow: 0 4px 15px rgba(255,60,0,0.4);
    border: none;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

    .navbar .btn-shop:hover {
        background: linear-gradient(90deg, #ffb300 0%, #ff3c00 100%);
        color: #fff;
        box-shadow: 0 6px 20px rgba(255,107,53,0.6);
        transform: translateY(-2px);
    }

/* ============================================
   AUTH BUTTONS (Uloguj se / Registruj se)
   ============================================ */
.btn-auth-login {
    background: rgba(40, 167, 69, 0.15);
    color: white;
    border: 2px solid #28a745;
    border-radius: 30px;
    padding: 0.6rem 1.6rem;
    font-weight: 700;
    transition: all 0.3s;
    box-shadow: 0 0 15px rgba(40, 167, 69, 0.3);
}

.btn-auth-login:hover {
    background: #28a745;
    border-color: #28a745;
    color: white;
    box-shadow: 0 0 25px rgba(40, 167, 69, 0.6);
    transform: translateY(-2px);
}

.btn-auth-register {
    background: rgba(220, 53, 69, 0.15);
    color: white;
    border: 2px solid #dc3545;
    border-radius: 30px;
    padding: 0.6rem 1.6rem;
    font-weight: 700;
    transition: all 0.3s;
    box-shadow: 0 0 15px rgba(220, 53, 69, 0.3);
}

.btn-auth-register:hover {
    background: #dc3545;
    border-color: #dc3545;
    color: white;
    box-shadow: 0 0 25px rgba(220, 53, 69, 0.6);
    transform: translateY(-2px);
}

/* ============================================
   AUTH BUTTONS (Uloguj se / Registruj se) - MOBILE
   ============================================ */
.auth-buttons-mobile {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    margin-top: 0.6rem;
    margin-bottom: 1.5rem;
}

.auth-buttons-mobile .btn-auth-login,
.auth-buttons-mobile .btn-auth-register {
    width: 100%;
    padding: 0.65rem 1rem;
    font-size: 1rem;
    border-radius: 25px;
}

/* Smanjeni razmak izme─æu auth dugmadi i "Predaj oglas" na mobilnom */
@media (max-width: 992px) {
    .navbar-collapse .auth-buttons-mobile + .btn-shop {
        margin-top: 0.4rem;
    }
    
    .navbar .btn-shop {
        padding: 0.54rem 1.44rem;
        font-size: 0.99rem;
        margin: 0 auto;
        display: block;
        width: 80%;
    }
}

/* ============================================
   FOOTER - Racing Style
   ============================================ */
.footer-custom {
    margin-top: auto;
}

.footer-content {
    background: rgba(34,34,34,0.95);
    border-radius: 24px 24px 0 0;
    box-shadow: 0 -4px 24px rgba(0,0,0,0.4);
    padding: 1.5rem 2rem;
    border-top: 2px solid #ff3c00;
}

@media (max-width: 991.98px) {
    .footer-content .row .order-1 {
        margin-bottom: 0.85rem;
    }

    .footer-content .row .order-2 {
        padding-top: 0.15rem;
    }
}

.footer-brand {
    font-weight: bold;
    color: #ff3c00;
    text-shadow: 0 0 10px rgba(255,60,0,0.5);
}







