:root {
    --primary-color: #4361ee;
    --secondary-color: #3f37c9;
    --accent-color: #4cc9f0;
    --dark-color: #1a1a2e;
    --light-color: #f8f9fa;
    --success-color: #38b000;
}

html {
    overflow-y: scroll; 
}

body {
    font-family: 'Poppins', sans-serif;
    color: #333;
    background-color: #f8f9fa;
    line-height: 1.6;

    padding-right: 0 !important; 
    transition: padding-right 0.3s ease; 
}

h1, h2, h3, h4, h5 {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
}

/* Navbar */
.navbar {
    background-color: rgba(255, 255, 255, 0.95) !important;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.2);
    padding: 15px 0;
    transition: all 0.3s ease;
}

.navbar.scrolled {
    padding: 10px 0;
    background-color: rgba(255, 255, 255, 0.98) !important;
}

.navbar-search {
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-icon-circle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: rgba(0, 0, 0, 0.05);
    border-radius: 50%;
    transition: all 0.3s ease;
}

.search-icon-circle svg {
    width: 18px;
    height: 18px;
    color: var(--dark-color);
}

.search-icon-circle:hover {
    background-color: rgba(0, 0, 0, 0.1);
    transform: scale(1.05);
}

@media (max-width: 768px) {
    .search-icon-circle {
        width: 36px;
        height: 36px;
    }
    
    .search-icon-circle svg {
        width: 16px;
        height: 16px;
    }
}

.navbar-menu {
    display: flex;
    align-items: center;
    justify-content: center;
}

.menu-icon-circle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: rgba(0, 0, 0, 0.05);
    border-radius: 50%;
    transition: all 0.3s ease;
}

.menu-icon-circle svg {
    width: 18px;
    height: 18px;
    color: var(--dark-color);
}

.menu-icon-circle:hover {
    background-color: rgba(0, 0, 0, 0.1);
    transform: scale(1.05);
}

@media (max-width: 768px) {
    .menu-icon-circle {
        width: 36px;
        height: 36px;
    }
    
    .menu-icon-circle svg {
        width: 16px;
        height: 16px;
    }
}

/* .navbar-brand img {
    height: 50px;
    transition: all 0.3s ease;
}

.navbar-brand {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
} */

.navbar-menu img {
    height: 50px;
    transition: all 0.3s ease;
}

.navbar-collapse {
    flex-grow: 0; 
}

.navbar > .container {
    display: flex;
    justify-content: space-between;
    width: 100%;
    flex-wrap: wrap;
    position: relative;
}

.nav-link {
    font-weight: 500;
    color: var(--dark-color) !important;
    margin: 0 8px;
    position: relative;
    padding: 8px 12px !important;
}
  
.nav-link:after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}
  
.nav-link:hover:after {
    width: 100%;
}
  
.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    padding: 10px 25px;
    border-radius: 30px;
    font-weight: 500;
    transition: all 0.3s ease;
}
  
.btn-primary:hover {
    background-color: var(--secondary-color);
    border-color: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(67, 97, 238, 0.3);
}
  
/* Animations */
@keyframes fadeInUp {
    from {
      opacity: 0;
      transform: translateY(20px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
}
  
.fade-in-up {
    animation: fadeInUp 0.8s ease forwards;
}
  
@media (max-width: 992px) {
    .hero-section h1 {
      font-size: 2.8rem;
    }
}
  
@media (max-width: 768px) {
    .hero-section {
      height: auto;
      padding: 100px 0;
    }
    
    .hero-section h1 {
      font-size: 2.2rem;
    }
    
    .hero-section p {
      font-size: 1rem;
    }

    /* .navbar-brand img {
        height: 40px;
    } */

    .navbar-menu img {
        height: 40px;
    }
}

/* Similar Books Section */
.similar-section {
    padding: 100px 0 60px;
    background-color: #f8f9fa;
}

.section-title {
    position: relative;
    display: flex;
    justify-content: center;
    margin-bottom: 60px; 
    margin-top: 20px; 
}

.section-title:after {
    content: '';
    position: absolute;
    width: 15%;
    height: 3px;
    bottom: -15px; 
    left: 1;
    background: linear-gradient(to right, var(--primary-color), var(--accent-color));
}

.book-card {
    border: none;
    border-radius: 10px;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.book-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

.book-cover-container {
    position: relative;
    overflow: hidden;
    height: 250px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f8f9fa;
}

.book-cover {
    width: auto;
    height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.book-card:hover .book-cover {
    transform: scale(1.03);
}

.book-actions {
    position: absolute;
    top: 10px;
    right: 10px;
    display: flex;
    gap: 5px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.book-card:hover .book-actions {
    opacity: 1;
}

.book-actions .btn {
    width: 30px;
    height: 30px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.book-meta {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}

.book-meta .badge {
    font-weight: 500;
    padding: 5px 10px;
    border-radius: 20px;
}

/* Book Details Section */
.book-details-section {
    padding: 80px 0 40px;
    background-color: #fff;
    margin-bottom: 80px;
}

.book-details-container {
    max-width: 1200px;
    margin: 0 auto;
    background: #fff;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.book-main-info {
    display: flex;
    padding: 40px;
    gap: 40px;
    border-bottom: 1px solid #eee;
}

.book-cover-wrapper {
    position: relative;
    flex: 0 0 300px;
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f8f9fa;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.book-status-badge {
    display: inline-block; 
    padding: 6px 14px;     
    font-size: 0.9rem;    
    font-weight: 600;     
    border-radius: 10px; 
    line-height: 1;
    text-transform: uppercase;
    color: white;
}

.book-detail-cover {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.book-status-badge {
    position: absolute;
    top: 15px;
    right: 15px;
}

.book-status-badge .badge {
    padding: 8px 15px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.book-status-badge .available {
    background-color: #d4edda;
    color: #1a6b2d;
}

.book-status-badge .unavailable {
    background-color: #f8d7da;
    color: #8a222d;
}

.book-primary-info {
    flex: 1;
}

.book-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: #1a1a2e;
}

.book-author {
    font-size: 1.5rem;
    font-weight: 500;
    color: #6c757d;
    margin-bottom: 30px;
}

.book-meta-info {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 30px;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    color: #495057;
}

.meta-item i {
    color: #4361ee;
}

.book-actionss {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}

.btn-reserve, .btn-favorite {
    padding: 12px 25px !important;
    border-radius: 30px !important;
    font-weight: 500 !important;
    transition: all 0.3s ease !important;
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
}

.btn-reserve {
    background-color: #4361ee !important;
    color: white !important;
    border: none !important;
}

.btn-reserve:hover {
    background-color: #3a56d4 !important;;
    transform: translateY(-2px) !important;
    color: white !important;
    box-shadow: 0 5px 15px rgba(67, 97, 238, 0.3) !important;
}

.btn-reserve.disabled-status {
    background-color: #6c757d !important; 
    border-color: #6c757d !important;
    opacity: 0.6;
    cursor: not-allowed; 
    pointer-events: none; 
    box-shadow: none !important;
    transform: none !important;
}

.btn-favorite {
    background-color: transparent !important;
    color: #4361ee !important;
    border: 1px solid #4361ee !important;
}

.btn-favorite:hover {
    background-color: rgba(67, 97, 238, 0.2) !important;
    transform: translateY(-2px) !important;
}

.book-secondary-info {
    padding: 40px;
}

.info-tabs {
    margin-top: 40px;
}

.info-tabs .nav-tabs {
    border-bottom: 2px solid #dee2e6;
    margin-bottom: 30px;
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    -ms-overflow-style: -ms-autohiding-scrollbar;
}

.info-tabs .nav-tabs::-webkit-scrollbar {
    display: none;
}

.info-tabs .nav-link {
    padding: 12px 25px;
    border: none;
    color: #6c757d;
    font-weight: 500;
    position: relative;
    background: none;
    white-space: nowrap;
    transition: color 0.2s ease;
    margin-right: 5px;
}

.info-tabs .nav-link:last-child {
    margin-right: 0;
}

.info-tabs .nav-link:hover {
    color: #4361ee;
    transform: none; 
}

.info-tabs .nav-link.active {
    color: #4361ee;
    background: none;
    font-weight: 600;
}

.info-tabs .nav-link.active:after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: #4361ee;
    border-radius: 3px 3px 0 0;
}

.info-tabs .nav-link:not(.active):hover {
    background-color: rgba(67, 97, 238, 0.05);
    border-radius: 5px 5px 0 0;
}

.tab-content {
    padding: 20px 0;
    line-height: 1.8;
    color: #495057;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.quote-block {
    background-color: #f8f9fa;
    border-left: 4px solid #4361ee;
    padding: 20px;
    margin: 30px 0;
    position: relative;
}

.quote-block i:first-child {
    position: absolute;
    top: 10px;
    left: 10px;
    color: rgba(67, 97, 238, 0.2);
    font-size: 1.5rem;
}

.quote-block i:last-child {
    position: absolute;
    bottom: 10px;
    right: 10px;
    color: rgba(67, 97, 238, 0.2);
    font-size: 1.5rem;
}

.quote-block blockquote {
    margin: 0;
    padding: 0 20px;
    font-style: italic;
    color: #6c757d;
}

.details-card {
    background: #ffffff;
    border-radius: 15px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
    padding: 30px;
    transition: all 0.3s ease;
}

.details-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 20px;
}

.detail-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.detail-item:hover {
    background-color: #e9ecef;
    transform: translateY(-3px);
}

.detail-icon {
    background-color: #4361ee;
    color: white;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 20px;
    flex-shrink: 0;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

.detail-text {
    display: flex;
    flex-direction: column;
}

.detail-label {
    font-weight: 600;
    font-size: 1rem;
    color: var(#1a1a2e);
    margin-bottom: 5px;
}

.detail-value {
    color: #6c757d;
    font-size: 0.95rem;
}

.detail-value i {
    color: #ffc107;
}


.review-form {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 30px;
}

.review-form h4 {
    margin-bottom: 15px;
}

.rating-stars {
    margin-bottom: 15px;
}

.rating-stars i {
    font-size: 1.5rem;
    color: #ffc107;
    cursor: pointer;
    transition: all 0.2s;
}

.rating-stars i:hover {
    transform: scale(1.2);
}

.review-form textarea {
    min-height: 120px;
    margin-bottom: 15px;
    resize: none; 
    overflow-y: hidden; 
    transition: height 0.2s ease;
    padding: 15px;
    border-radius: 10px;
    border: 1px solid #dee2e6;
    width: 100%;
}

.review-form textarea {
    display: block;
    box-sizing: padding-box;
    overflow: hidden;
}

.btn-submit-review {
    background-color: var(--primary-color) !important;
    color: white !important;
    padding: 12px 30px !important;
    border-radius: 30px !important;
    border: none !important;
    font-weight: 500 !important;
    transition: all 0.3s ease !important;
    position: relative !important;
    overflow: hidden !important;
    box-shadow: 0 4px 15px rgba(67, 97, 238, 0.2) !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
}

.btn-submit-review:hover {
    background-color: var(--secondary-color) !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 20px rgba(67, 97, 238, 0.3) !important;
}

.btn-submit-review:active {
    transform: translateY(0);
}

.btn-submit-review::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 5px;
    height: 5px;
    background: rgba(255, 255, 255, 0.5);
    opacity: 0;
    border-radius: 100%;
    transform: scale(1, 1) translate(-50%);
    transform-origin: 50% 50%;
}

.btn-submit-review:hover::after {
    animation: ripple 1s ease-out;
}

@keyframes ripple {
    0% {
        transform: scale(0, 0);
        opacity: 0.5;
    }
    100% {
        transform: scale(20, 20);
        opacity: 0;
    }
}

.reviews-list {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.review-item {
    padding: 20px;
    border-radius: 10px;
    background-color: #f8f9fa;
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.review-author {
    font-weight: 600;
    color: #343a40;
}

.review-rating i {
    color: #ffc107;
    font-size: 0.9rem;
}

.review-date {
    font-size: 0.8rem;
    color: #6c757d;
    margin-bottom: 10px;
}

.review-content {
    line-height: 1.6;
}

/* popUp za pozajmice */
.modern-popup-border {
    border-radius: 24px !important;
    padding: 0 !important;
    overflow: hidden !important;
    box-shadow: 0 25px 60px rgba(67, 97, 238, 0.18), 0 8px 20px rgba(0,0,0,0.1) !important;
    border: none !important;
}

.modern-popup-border::before {
    content: '';
    display: block;
    height: 5px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    border-radius: 24px 24px 0 0;
}

.swal2-popup.modern-popup-border .swal2-header {
    padding: 28px 32px 10px !important;
}

.swal2-popup.modern-popup-border .swal2-content {
    padding: 0 32px !important;
}

.swal2-popup.modern-popup-border .swal2-actions {
    padding: 16px 32px 28px !important;
    gap: 10px !important;
}

.swal2-icon.swal2-question {
    border-color: #4361ee !important;
    color: #4361ee !important;
}

.swal2-icon.swal2-info {
    border-color: #4cc9f0 !important;
    color: #4cc9f0 !important;
}

.swal2-icon.swal2-success {
    border-color: #38b000 !important;
}

.swal2-icon.swal2-success [class^='swal2-success-line'] {
    background-color: #38b000 !important;
}

.swal2-icon.swal2-success .swal2-success-ring {
    border-color: rgba(56, 176, 0, 0.3) !important;
}

.modern-popup-title {
    font-family: 'Poppins', sans-serif !important;
    font-weight: 700 !important;
    font-size: 1.3rem !important;
    color: #1a1a2e !important;
    letter-spacing: -0.3px;
}

.btn-modern-confirm, .btn-modern-cancel {
    padding: 11px 28px !important;
    margin: 4px 6px !important;
    border-radius: 50px !important;
    font-weight: 600 !important;
    font-size: 0.88rem !important;
    letter-spacing: 0.3px !important;
    transition: all 0.25s ease !important;
    border: none !important;
    cursor: pointer !important;
}

.btn-modern-confirm {
    background: linear-gradient(135deg, #4361ee, #3f37c9) !important;
    color: white !important;
    box-shadow: 0 4px 15px rgba(67, 97, 238, 0.35) !important;
}

.btn-modern-confirm:hover {
    background: linear-gradient(135deg, #3046bc, #2d27a8) !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 20px rgba(67, 97, 238, 0.45) !important;
}

.btn-modern-confirm:active {
    transform: translateY(0) !important;
}

.btn-modern-cancel {
    background-color: #f0f2f5 !important;
    color: #555e72 !important;
    box-shadow: none !important;
}

.btn-modern-cancel:hover {
    background-color: #e2e5eb !important;
    color: #333 !important;
    transform: translateY(-1px) !important;
}

.res-info {
    background: linear-gradient(135deg, #f0f4ff 0%, #f8f9ff 100%);
    padding: 18px 20px;
    border-radius: 14px;
    border-left: 4px solid #4361ee;
    margin-top: 12px;
    text-align: left;
}

.res-info hr {
    border-color: rgba(67, 97, 238, 0.15);
    margin: 12px 0;
}

.res-info small {
    color: #8892a4;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

.res-info strong {
    color: #1a1a2e;
    font-size: 1rem;
}

.res-info p {
    color: #444;
    margin-bottom: 4px;
}

.swal2-html-container div[style*="background:#f0f4ff"],
.swal2-html-container div[style*="background:#fff8e1"] {
    border-radius: 12px !important;
    padding: 14px 16px !important;
    border: 1px solid rgba(67, 97, 238, 0.12) !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04) !important;
}

.swal2-input {
    border-radius: 10px !important;
    border: 1.5px solid #dde2f0 !important;
    padding: 10px 14px !important;
    font-family: 'Poppins', sans-serif !important;
    font-size: 0.9rem !important;
    transition: border-color 0.2s, box-shadow 0.2s !important;
    box-shadow: none !important;
}

.swal2-input:focus {
    border-color: #4361ee !important;
    box-shadow: 0 0 0 3px rgba(67, 97, 238, 0.12) !important;
    outline: none !important;
}

.swal2-validation-message {
    border-radius: 8px !important;
    font-size: 0.85rem !important;
    background: #fff0f0 !important;
    color: #c0392b !important;
    border: 1px solid #fcc !important;
}

.swal2-html-container strong {
    color: #4361ee;
}

.swal2-backdrop-show {
    background: rgba(26, 26, 46, 0.55) !important;
    backdrop-filter: blur(3px) !important;
}

@media (max-width: 992px) {
    .book-main-info {
        flex-direction: column;
    }
    
    .book-cover-wrapper {
        flex: 0 0 auto;
        height: 350px;
        margin-bottom: 30px;
    }
    
    .book-title {
        font-size: 2rem;
    }
    
    .book-author {
        font-size: 1.3rem;
    }
}

@media (max-width: 768px) {
    .book-main-info, .book-secondary-info {
        padding: 25px;
    }
    
    .book-title {
        font-size: 1.8rem;
    }
    
    .book-meta-info {
        gap: 15px;
    }
    
    .info-tabs .nav-link {
        padding: 10px 15px;
        font-size: 0.9rem;
    }
    
    .details-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 576px) {
    .book-cover-wrapper {
        height: 300px;
    }
    
    .book-actions {
        flex-direction: column;
    }
    
    .btn-reserve, .btn-favorite {
        width: 100%;
        justify-content: center;
    }
}

/* Uvid u primerke */
.copies-container {
    padding: 20px 0;
}

.copies-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.copy-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 20px;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    position: relative;
}

.copy-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 20px rgba(0, 0, 0, 0.08);
    border-color: var(--primary-color);
}

.copy-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.inventory-number {
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--dark-color);
}

.inventory-number::before {
    content: 'ID: ';
    font-size: 0.8rem;
    color: #94a3b8;
    font-weight: 400;
}

.copy-body {
    flex-grow: 1;
    margin-bottom: 15px;
}

.copy-info-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    padding: 8px 0;
    border-bottom: 1px dashed #f1f5f9;
}

.copy-info-row .label {
    color: #64748b;
}

.copy-info-row .value {
    font-weight: 500;
    color: var(--dark-color);
}

.badge-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.badge-dostupno {
    background: #ecfdf5;
    color: #059669;
    border: 1px solid #a7f3d0;
}

.badge-rezervisano {
    background: #fffbeb;
    color: #d97706;
    border: 1px solid #fde68a;
}

.badge-pozajmljeno {
    background: #fef2f2;
    color: #dc2626;
    border: 1px solid #fecaca;
}

.btn-pozajmi {
    width: 100%;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    padding: 10px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-pozajmi:hover {
    opacity: 0.9;
    color: white;
}

.btn-pozajmi i {
    font-size: 0.9rem;
}

@media (max-width: 576px) {
    .copies-grid {
        grid-template-columns: 1fr;
    }
}