/**
 * Thép Gia Tín Custom Styling Sheet
 * Modern Industrial B2B E-commerce theme
 */

html {
    height: 100%;
}

body {
    font-family: 'Outfit', sans-serif;
    color: #333333;
    background-color: #F8F9FA;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

footer {
    margin-top: auto !important;
}

/* Custom Color Tokens */
.text-warning {
    color: #FFC107 !important;
}

.bg-danger {
    background-color: #C82333 !important;
}

.text-danger {
    color: #C82333 !important;
}

.border-danger {
    border-color: #C82333 !important;
}

.bg-dark {
    background-color: #212529 !important;
}

/* Header & Top Bar */
.top-bar {
    background-color: #1A1D20;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.top-bar small {
    font-size: 0.8rem;
    letter-spacing: 0.02rem;
}

.lang-switch {
    font-size: 0.8rem;
    opacity: 0.75;
    transition: opacity 0.3s;
}

.lang-switch:hover {
    opacity: 1;
}

/* Sticky Navbar logo & fonts */
.navbar-brand img {
    border-radius: 4px;
}

.brand-title {
    letter-spacing: 0.05rem;
    line-height: 1.1;
}

.brand-subtitle {
    font-size: 0.6rem;
    letter-spacing: 0.08rem;
    opacity: 0.85;
}

.navbar-nav .nav-link {
    font-size: 0.85rem;
    letter-spacing: 0.03rem;
    color: rgba(255, 255, 255, 0.8) !important;
    transition: color 0.3s ease;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    color: #FFC107 !important;
}

/* Autocomplete search bar */
.search-form {
    min-width: 200px;
}

.search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 1000;
    max-height: 300px;
    overflow-y: auto;
    display: none;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
}

.suggestion-item {
    cursor: pointer;
    font-size: 0.8rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: background-color 0.2s;
}

.suggestion-item:hover {
    background-color: rgba(255, 255, 255, 0.05);
}

.suggestion-item:last-child {
    border-bottom: 0;
}

/* Premium Slanted Carousel Slide Design */
.carousel-item-split {
    position: relative;
    height: 500px;
    background-color: #0f1115;
    overflow: hidden;
}

.slide-content-panel {
    position: absolute;
    top: 0;
    left: 0;
    width: 52%;
    height: 100%;
    background: linear-gradient(135deg, #163c70 0%, #0b2247 100%);
    z-index: 3;
    padding-left: 8%;
    padding-right: 5%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    clip-path: polygon(0 0, 100% 0, 88% 100%, 0 100%);
}

.slide-image-panel {
    position: absolute;
    top: 0;
    right: 0;
    width: 54%;
    height: 100%;
    z-index: 1;
}

.slide-image-panel img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: left center;
}

@media (max-width: 991.98px) {
    .slide-content-panel {
        width: 100%;
        padding-left: 5%;
        padding-right: 5%;
        clip-path: none;
        background: rgba(11, 34, 71, 0.92) !important;
    }

    .slide-image-panel {
        width: 100%;
        opacity: 0.3;
    }
}

.carousel-caption {
    z-index: 2;
}

.text-shadow {
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.95), 0 0 10px rgba(0, 0, 0, 0.5);
}

.fs-8 {
    font-size: 0.85rem !important;
}

.fs-9 {
    font-size: 1rem !important;
}

.fs-10 {
    font-size: 0.7rem !important;
}

/* Micro-animations & hover transitions */
.transition-3s {
    transition: all 0.3s ease;
}

.hover-scale {
    transform: scale(1);
    transition: transform 0.4s ease;
}

.hover-scale:hover {
    transform: scale(1.05);
}

.hover-translate-y {
    transform: translateY(0);
}

.hover-translate-y:hover {
    transform: translateY(-5px);
}

.hover-shadow:hover {
    box-shadow: 0 .5rem 1rem rgba(0, 0, 0, 0.15) !important;
}

.hover-opacity:hover {
    opacity: 0.85;
}

.hover-warning:hover {
    color: #FFC107 !important;
}

/* Category & Product Cards */
.category-card {
    border: 1px solid rgba(0, 0, 0, 0.06);
}

.category-card .card-img-wrapper {
    overflow: hidden;
}

.product-card {
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.06) !important;
}

.product-card-img-wrapper {
    overflow: hidden;
}

.product-card:hover .product-overlay-buttons {
    opacity: 1 !important;
}

.product-overlay-buttons {
    z-index: 5;
}

.text-truncate-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    height: 2.4rem;
}

.text-truncate-1 {
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Sidebar Styling */
.sidebar .widget {
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.06);
}

.widget-title {
    font-size: 0.95rem;
    letter-spacing: 0.02rem;
}

.sidebar-menu-list a {
    font-size: 0.85rem;
    background-color: #F8F9FA;
    border: 1px solid rgba(0, 0, 0, 0.03);
}

.sidebar-menu-list a:hover,
.sidebar-menu-list a.active {
    background-color: #C82333;
    color: #ffffff !important;
}

/* Product Detail Zoom and Tabs */
.main-image-frame {
    background-color: #ffffff;
}

.product-gallery-container {
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
}

.cursor-zoom-in {
    cursor: zoom-in;
}

.cursor-pointer {
    cursor: pointer;
}

.thumb-item {
    transition: border-color 0.2s;
}

.nav-tabs .nav-link {
    font-size: 0.85rem;
    color: #495057;
}

.nav-tabs .nav-link.active {
    color: #C82333 !important;
    border-color: #C82333 #C82333 #fff !important;
    border-width: 2px 2px 1px 2px !important;
    font-weight: bold;
}

/* Floating Actions bouncy effects */
.animate-bounce {
    animation: bounce 2s infinite;
}

@keyframes bounce {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-5px);
    }
}

.animate-pulse {
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(255, 193, 7, 0.7);
    }

    70% {
        transform: scale(1.05);
        box-shadow: 0 0 0 8px rgba(255, 193, 7, 0);
    }

    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(255, 193, 7, 0);
    }
}

.animate-wiggle {
    animation: wiggle 2.5s infinite;
}

@keyframes wiggle {

    0%,
    100% {
        transform: rotate(0);
    }

    10%,
    30%,
    50%,
    70%,
    90% {
        transform: rotate(-5deg);
    }

    20%,
    40%,
    60%,
    80% {
        transform: rotate(5deg);
    }
}

/* Modals & Dialog fields */
.modal-content {
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
}

.btn-xs {
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
    border-radius: 0.2rem;
}

.object-fit-cover {
    object-fit: cover;
}

.object-fit-contain {
    object-fit: contain;
}

/* Technical Specs List with Red Checkmarks */
.product-specs-list ul {
    list-style-type: none !important;
    padding-left: 0 !important;
    margin-bottom: 0 !important;
}

.product-specs-list li {
    position: relative !important;
    padding-left: 1.75rem !important;
    margin-bottom: 0.6rem !important;
    font-size: 0.85rem !important;
    color: #212529 !important;
    line-height: 1.4 !important;
}

.product-specs-list li::before {
    content: "✓" !important;
    color: #dc3545 !important;
    /* Red checkmark */
    font-weight: 900 !important;
    position: absolute !important;
    left: 0 !important;
    top: -1px !important;
    font-size: 1.05rem !important;
}

.product-specs-list span {
    font-size: inherit !important;
    color: inherit !important;
}

/* Responsive rich text content images (prevent layout overflow) */
#desc-content img,
.article-detail-content img,
.project-detail-content img,
.rich-text-content img {
    max-width: 100% !important;
    height: auto !important;
    object-fit: contain !important;
}