/* Custom Styles for Robotik Website */

:root {
    --primary-color: #FF0000;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --danger-color: #FF0000;
    --warning-color: #ffc107;
    --info-color: #0dcaf0;
    --light-color: #f8f9fa;
    --dark-color: #212529;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
}

/* Hero Carousel Section */
.hero-carousel-section {
    margin-top: 0;
}

.hero-slide {
    background: linear-gradient(135deg, #FF0000 0%, #CC0000 100%);
    min-height: 500px;
    display: flex;
    align-items: center;
}

.min-vh-50 {
    min-height: 500px;
}

.bg-gradient-primary {
    background: linear-gradient(135deg, #FF0000 0%, #CC0000 100%);
}

.carousel-control-prev,
.carousel-control-next {
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    top: 50%;
    transform: translateY(-50%);
    opacity: 0.8;
}

.carousel-control-prev {
    left: 20px;
}

.carousel-control-next {
    right: 20px;
}

.carousel-control-prev:hover,
.carousel-control-next:hover {
    opacity: 1;
    background: rgba(255, 255, 255, 0.3);
}

.product-media {
    overflow: hidden;
}

.product-media img {
    width: 100%;
    height: auto;
    object-fit: cover;
}

.hero-section {
    background: linear-gradient(135deg, #FF0000 0%, #CC0000 100%);
    padding: 80px 0;
    margin-top: 0;
}

.hero-section h1 {
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: none;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.15) !important;
}

/* Service Cards */
.service-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #e9ecef;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.1) !important;
}

.service-icon {
    width: 80px;
    height: 80px;
    background: rgba(255, 0, 0, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Product Cards */
.product-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    overflow: hidden;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.15) !important;
}

.product-card img {
    transition: transform 0.3s ease;
}

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

/* Category Buttons */
.category-buttons {
    gap: 10px;
}

.cat-btn {
    padding: 10px 20px;
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    border-radius: 25px;
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: all 0.3s ease;
    display: inline-block;
    margin: 5px;
}

.cat-btn:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 0, 0, 0.3);
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: bold;
}

.navbar-nav .nav-link {
    font-weight: 500;
    transition: color 0.3s ease;
}

.navbar-nav .nav-link:hover {
    color: #fff !important;
}

.navbar-nav .nav-link.active {
    color: #fff !important;
    font-weight: 600;
}

.btn {
    border-radius: 8px;
    padding: 10px 20px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.badge {
    padding: 6px 12px;
    font-weight: 500;
}

footer {
    margin-top: auto;
}

footer a:hover {
    color: #fff !important;
    text-decoration: underline !important;
}

/* Product Card Styles */
.card-img-top {
    transition: transform 0.3s ease;
}

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

/* Blog Card Styles */
.content {
    line-height: 1.8;
    color: #333;
}

.content p {
    margin-bottom: 1rem;
}

/* Table Styles */
.table {
    border-radius: 8px;
    overflow: hidden;
}

.table thead {
    background-color: var(--primary-color);
    color: white;
}

/* Form Styles */
.form-control:focus,
.form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(255, 0, 0, 0.25);
}

/* Loading Animation */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255,255,255,.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Responsive */
@media (max-width: 768px) {
    .hero-section {
        padding: 40px 0;
    }
    
    .hero-section h1 {
        font-size: 2rem;
    }
    
    .hero-carousel-section {
        margin-top: 0;
    }
    
    .hero-slide {
        min-height: 300px;
        padding: 20px 0;
    }
    
    .min-vh-50 {
        min-height: 300px;
    }
    
    .carousel-control-prev,
    .carousel-control-next {
        width: 35px;
        height: 35px;
    }
    
    .carousel-control-prev {
        left: 10px;
    }
    
    .carousel-control-next {
        right: 10px;
    }
    
    .card {
        margin-bottom: 20px;
    }
    
    .category-buttons {
        justify-content: center;
    }
    
    .cat-btn {
        font-size: 0.9rem;
        padding: 8px 16px;
    }
}

/* Smooth Scroll */
html {
    scroll-behavior: smooth;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #CC0000;
}

/* Video Playlist Styles */
.playlist-container {
    scrollbar-width: thin;
    scrollbar-color: var(--primary-color) #f1f1f1;
}

.playlist-item {
    padding: 6px 10px;
    border-bottom: 1px solid #e9ecef;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.playlist-item:hover {
    background-color: #f8f9fa;
}

.playlist-item.active {
    background-color: #fff5f5;
    border-left: 3px solid var(--primary-color);
}

.playlist-thumbnail {
    position: relative;
    width: 100px;
    height: 56px;
    flex-shrink: 0;
    margin-right: 8px;
    border-radius: 3px;
    overflow: hidden;
    background: #000;
}

.playlist-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.7);
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    font-size: 0.8rem;
}

.playlist-item:hover .play-icon {
    opacity: 1;
}

.playlist-info {
    flex: 1;
    min-width: 0;
}

.playlist-info h6 {
    font-size: 0.75rem;
    line-height: 1.2;
    margin-bottom: 0;
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.playlist-info .text-muted {
    font-size: 0.7rem;
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* Video Carousel Styles */
.video-carousel-container {
    position: relative;
    overflow: hidden;
}

.video-carousel {
    display: flex;
    gap: 15px;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding: 10px 0;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.video-carousel::-webkit-scrollbar {
    display: none;
}

.video-carousel-item {
    flex: 0 0 200px;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.video-carousel-item:hover {
    transform: translateY(-5px);
}

.video-thumbnail-wrapper {
    position: relative;
    width: 200px;
    height: 112px;
    border-radius: 8px;
    overflow: hidden;
    background: #000;
}

.video-thumbnail {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.play-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.video-carousel-item:hover .play-overlay {
    opacity: 1;
}

.play-overlay i {
    font-size: 3rem;
    color: white;
}

.video-title-small {
    font-size: 0.85rem;
    font-weight: 500;
    margin: 0;
    line-height: 1.3;
    color: #333;
}

.carousel-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
}

.carousel-nav:hover {
    background: white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.carousel-prev {
    left: 10px;
}

.carousel-next {
    right: 10px;
}

.carousel-nav i {
    font-size: 1.5rem;
    color: var(--primary-color);
}

/* Responsive Video Section */
@media (max-width: 992px) {
    .playlist-container {
        max-height: 400px !important;
    }
    
    .playlist-thumbnail {
        width: 100px;
        height: 56px;
    }
    
    .video-carousel-item {
        flex: 0 0 150px;
    }
    
    .video-thumbnail-wrapper {
        width: 150px;
        height: 84px;
    }
}

@media (max-width: 768px) {
    .playlist-thumbnail {
        width: 80px;
        height: 45px;
    }
    
    .playlist-info h6 {
        font-size: 0.75rem;
    }
}
