/* Common Components Styles */
/* ======================== */

/* Navbar Styles */
.navbar-section {
    position: relative;
    z-index: 1000;
}

.navbar {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    padding: 0.5rem 0;
    min-height: 60px;
}

.navbar-brand {
    font-weight: 700;
    font-size: 1.25rem;
    color: #dc3545 !important;
    text-decoration: none;
    display: flex !important;
    align-items: center !important;
    height: 48px;
}

.brand-text {
    color: #dc3545;
    font-weight: 700;
    line-height: 3;
}

.navbar-nav {
    align-items: flex-start !important;
    margin-top: 6px;
}

.nav-link {
    font-weight: 500;
    color: #333 !important;
    transition: color 0.3s ease;
    margin: 0 0.25rem;
    padding: 0.5rem 0.75rem !important;
    font-size: 0.9rem;
    line-height: 1.2;
    display: flex !important;
    align-items: center !important;
    height: auto;
}

.nav-link:hover {
    color: #dc3545 !important;
}

.nav-link.active {
    color: #dc3545 !important;
    font-weight: 600;
}

.navbar .container {
    display: flex;
    align-items: center;
}

.navbar-collapse {
    align-items: center;
}

.navbar-nav .nav-item {
    display: flex;
    align-items: flex-start;
}

/* User Dropdown Button Styling */
.user-dropdown-btn {
    min-width: 180px !important;
    max-width: 250px !important;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    justify-content: space-between !important;
}

.user-name-text {
    flex: 1;
    text-align: left;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 150px;
}

/* User Dropdown Alignment */
.navbar .d-flex {
    height: auto;
    margin-top: 8px;
}

.navbar .dropdown .btn {
    height: auto;
    display: flex !important;
    align-items: center !important;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    border: 2px solid #dc3545;
}

.navbar .dropdown .btn:hover {
    transform: none;
    box-shadow: none;
}

/* Auth buttons specific styles*/ 
.navbar .btn {
    font-size: 0.9rem;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-weight: 500;
    min-width: auto;
    white-space: nowrap;
}

.navbar .btn i {
    font-size: 0.85rem;
}

/* Footer Styles */
.footer-section {
    background: #343a40;
    color: white;
    padding: 3rem 0 1rem;
}

.footer-brand img {
    max-width: 150px;
    margin-bottom: 1rem;
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: 50%;
    margin-right: 0.5rem;
    transition: all 0.3s ease;
}

.social-links a:hover {
    background: #dc3545;
    transform: translateY(-2px);
}

.footer-links a {
    color: #6c757d;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #dc3545;
}

/* Button Styles */
.btn {
    font-weight: 600;
    border-radius: 50px;
    transition: all 0.3s ease;
    padding: 0.75rem 2rem;
}

.btn-primary {
    background: linear-gradient(135deg, #dc3545, #ff6b6b);
    border: none;
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(220, 53, 69, 0.3);
    color: white;
}

.btn-outline-primary {
    border: 2px solid #dc3545;
    color: #dc3545;
    background: transparent;
}

.btn-outline-primary:hover {
    background: #dc3545;
    border-color: #dc3545;
    color: white;
    transform: translateY(-2px);
}

.btn-danger {
    background: #dc3545;
    border-color: #dc3545;
    color: white;
}

.btn-danger:hover {
    background: #c82333;
    border-color: #c82333;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(220, 53, 69, 0.3);
}

.btn-outline-danger {
    border: 2px solid #dc3545;
    color: #dc3545;
    background: transparent;
}

.btn-outline-danger:hover {
    background: #dc3545;
    color: white;
    transform: translateY(-2px);
}

/* Card Styles */
.card {
    border: none;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    overflow: hidden;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
}

.card-body {
    padding: 2rem;
}

.card-title {
    font-weight: 600;
    color: #333;
    margin-bottom: 1rem;
}

.card-text {
    color: #6c757d;
    line-height: 1.6;
}

/* Alert Styles */
.alert {
    border: none;
    border-radius: 10px;
    padding: 1rem 1.5rem;
}

.alert-info {
    background: rgba(23, 162, 184, 0.1);
    color: #0c5460;
}

.alert-warning {
    background: rgba(255, 193, 7, 0.1);
    color: #856404;
}

.alert-success {
    background: rgba(40, 167, 69, 0.1);
    color: #155724;
}

.alert-danger {
    background: rgba(220, 53, 69, 0.1);
    color: #721c24;
}

/* Badge Styles */
.badge {
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 50px;
}

.badge-primary {
    background: #dc3545;
    color: white;
}

.badge-secondary {
    background: #6c757d;
    color: white;
}

.badge-success {
    background: #28a745;
    color: white;
}

/* Icon Styles */
.fas, .fa {
    transition: transform 0.3s ease;
}

.card:hover .fas,
.card:hover .fa {
    transform: scale(1.1);
}

.text-primary {
    color: #dc3545 !important;
}

.text-secondary {
    color: #6c757d !important;
}

.text-success {
    color: #28a745 !important;
}

.text-danger {
    color: #dc3545 !important;
}

/* Form Styles */
.form-control {
    border-radius: 10px;
    border: 1px solid #dee2e6;
    padding: 0.75rem 1rem;
    transition: all 0.3s ease;
}

.form-control:focus {
    border-color: #dc3545;
    box-shadow: 0 0 0 0.25rem rgba(220, 53, 69, 0.25);
}

.form-label {
    font-weight: 600;
    color: #333;
    margin-bottom: 0.5rem;
}

/* Dropdown Styles */
.dropdown-menu {
    border: none;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    padding: 0.5rem 0;
}

.dropdown-item {
    padding: 0.75rem 1.5rem;
    transition: all 0.3s ease;
}

.dropdown-item:hover {
    background: rgba(220, 53, 69, 0.1);
    color: #dc3545;
}

.dropdown-header {
    font-weight: 600;
    color: #333;
    padding: 0.75rem 1.5rem;
}

/* Modal Styles */
.modal-content {
    border: none;
    border-radius: 15px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
}

.modal-header {
    border-bottom: 1px solid #dee2e6;
    padding: 1.5rem;
}

.modal-body {
    padding: 1.5rem;
}

.modal-footer {
    border-top: 1px solid #dee2e6;
    padding: 1.5rem;
}

/* Breadcrumb Styles */
.breadcrumb {
    background: transparent;
    padding: 0.5rem 0;
}

.breadcrumb-item a {
    color: #dc3545;
    text-decoration: none;
}

.breadcrumb-item.active {
    color: #6c757d;
}

/* Pagination Styles */
.page-link {
    border: none;
    color: #dc3545;
    padding: 0.75rem 1rem;
    margin: 0 0.25rem;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.page-link:hover {
    background: #dc3545;
    color: white;
    transform: translateY(-2px);
}

.page-item.active .page-link {
    background: #dc3545;
    border-color: #dc3545;
}

/* Progress Bar Styles */
.progress {
    height: 10px;
    border-radius: 10px;
    background: #e9ecef;
}

.progress-bar {
    background: linear-gradient(135deg, #dc3545, #ff6b6b);
    border-radius: 10px;
}

/* Tooltip Styles */
.tooltip {
    font-size: 0.875rem;
}

.tooltip-inner {
    background: #333;
    border-radius: 8px;
    padding: 0.5rem 1rem;
}

/* Back to Top Button */
.btn-floating {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: none;
    z-index: 1000;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    border: none;
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    color: white;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-floating:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 30px rgba(220, 53, 69, 0.4);
    background: linear-gradient(135deg, #c82333 0%, #a71e2a 100%);
    color: white;
}

.btn-floating:active {
    transform: translateY(-1px);
    box-shadow: 0 5px 15px rgba(220, 53, 69, 0.3);
}

.btn-floating i {
    font-size: 1rem;
    line-height: 1;
}

/* Back to Top Button Animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.btn-floating.show {
    display: flex !important;
    animation: fadeInUp 0.3s ease-out;
}

.btn-floating.hide {
    animation: fadeOutDown 0.3s ease-out;
}

@keyframes fadeOutDown {
    from {
        opacity: 1;
        transform: translateY(0);
    }
    to {
        opacity: 0;
        transform: translateY(30px);
    }
}

/* Pulse effect for better UX */
.btn-floating::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 50%;
    background: rgba(220, 53, 69, 0.3);
    animation: pulse-ring 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
    z-index: -1;
}

@keyframes pulse-ring {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    100% {
        transform: scale(1.5);
        opacity: 0;
    }
}

/* Responsive Utilities */
@media (max-width: 768px) {
    .btn {
        padding: 0.6rem 1.5rem;
        font-size: 0.9rem;
    }
    
    .card-body {
        padding: 1.5rem;
    }
    
    .navbar-brand {
        font-size: 1.1rem;
        height: 44px;
    }
    
    .navbar {
        padding: 0.4rem 0;
        min-height: 55px;
    }
    
    .nav-link {
        padding: 0.4rem 0.5rem !important;
        font-size: 0.85rem;
        height: auto;
    }
    
    .navbar-nav {
        margin-top: 6px;
    }
    
    .navbar .dropdown .btn {
        height: auto;
        padding: 0.4rem 0.8rem;
        min-width: 140px !important;
        max-width: 180px !important;
    }
    
    .user-name-text {
        max-width: 100px;
        font-size: 0.85rem;
    }
    
    .navbar .d-flex {
        margin-top: 6px;
    }
    
    .navbar .btn {
        font-size: 0.85rem;
        padding: 0.4rem 0.8rem;
    }
    
    .navbar .btn i {
        font-size: 0.8rem;
    }
}

@media (max-width: 576px) {
    .btn {
        padding: 0.5rem 1rem;
        font-size: 0.875rem;
    }
    
    .card-body {
        padding: 1rem;
    }
    
    .navbar {
        padding: 0.3rem 0;
        min-height: 50px;
    }
    
    .navbar-brand {
        font-size: 1rem;
        height: 40px;
    }
    
    .nav-link {
        padding: 0.3rem 0.4rem !important;
        font-size: 0.8rem;
        height: auto
    }
    
    .navbar-nav {
        margin-top: 4px;
    }
    
    .navbar .dropdown .btn {
        height: auto;
        padding: 0.3rem 0.6rem;
        font-size: 0.8rem;
        min-width: 120px !important;
        max-width: 150px !important;
    }
    
    .user-name-text {
        max-width: 80px;
        font-size: 0.75rem;
    }
    
    .navbar .d-flex {
        margin-top: 4px;
    }
    
    .navbar .btn {
        font-size: 0.8rem;
        padding: 0.3rem 0.6rem;
    }
    
    .navbar .btn span {
        font-size: 0.75rem;
    }
    
    .navbar .btn i {
        font-size: 0.75rem;
    }
    
    /* Stack auth buttons vertically on very small screens if needed */
    .navbar .d-flex.gap-2 {
        gap: 0.5rem !important;
    }
    
    .btn-floating {
        bottom: 1rem;
        right: 1rem;
        width: 45px;
        height: 45px;
        font-size: 1rem;
    }
    
    .btn-floating i {
        font-size: 0.9rem;
    }
}

/*Other Custom*/
.about-page .mb-3 {
    text-align: center;
}

.cta-section .btn-light:hover {
    color:#dc3545
}