/* Animal Detail Carousel Styles */
.animal-carousel {
    height: 300px;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    background-color: #f8f9fa;
}

@media (min-width: 768px) {
    .animal-carousel {
        height: 400px;
    }
}

@media (min-width: 1200px) {
    .animal-carousel {
        height: 500px;
    }
}

.animal-carousel .carousel-inner {
    height: 100%;
}

.animal-carousel .carousel-item {
    height: 100%;
    position: relative;
}

/* Image styling */
.animal-carousel .carousel-item img {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 4px;
}

/* Video container styling */
.animal-carousel .video-container {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 90%;
    height: 90%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* YouTube and Vimeo iframe styling */
.animal-carousel .video-container iframe {
    width: 100%;
    height: 100%;
    border-radius: 4px;
    max-width: 100%;
    max-height: 100%;
}

/* HTML5 video element styling */
.animal-carousel .video-container video {
    width: 100%;
    height: 100%;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 4px;
}

/* Video link placeholder styling */
.animal-carousel .video-link-container {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.animal-carousel .video-placeholder {
    text-align: center;
    padding: 2rem;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    border: 2px dashed #ccc;
}

.animal-carousel .video-placeholder i {
    font-size: 3rem;
    color: #007bff;
    margin-bottom: 1rem;
    display: block;
}

.animal-carousel .video-placeholder p {
    margin-bottom: 1rem;
    color: #666;
    font-size: 1.1rem;
}

.animal-carousel .video-placeholder .btn {
    font-size: 1.1rem;
    padding: 0.75rem 1.5rem;
}

/* Responsive video adjustments */
@media (max-width: 768px) {
    .animal-carousel .video-container {
        width: 95%;
        height: 85%;
    }
    
    .animal-carousel .video-placeholder i {
        font-size: 2rem;
    }
    
    .animal-carousel .video-placeholder p {
        font-size: 1rem;
    }
    
    .animal-carousel .video-placeholder .btn {
        font-size: 1rem;
        padding: 0.5rem 1rem;
    }
}

/* Carousel controls styling */
.animal-carousel .carousel-control-prev,
.animal-carousel .carousel-control-next {
    background: rgba(0, 0, 0, 0.5);
    width: 40px;
    border-radius: 50%;
    top: 50%;
    transform: translateY(-50%);
    height: 40px;
    opacity: 0.8;
    transition: opacity 0.3s ease;
    z-index: 10;
}

.animal-carousel .carousel-control-prev:hover,
.animal-carousel .carousel-control-next:hover {
    opacity: 1;
}

.animal-carousel .carousel-control-prev {
    left: 10px;
}

.animal-carousel .carousel-control-next {
    right: 10px;
}

.animal-carousel .carousel-indicators {
    bottom: 10px;
}

/* Animal Description Styles */
.animal-description {
    position: relative;
}

.animal-description p {
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 4px;
    padding: 1rem;
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.9rem;
    line-height: 1.5;
    white-space: pre-wrap;
    word-wrap: break-word;
    margin-bottom: 0.5rem;
}

.animal-description small {
    font-style: italic;
    display: block;
    margin-top: 0.25rem;
}

/* Animal Description Styles for HTML Content */
.animal-description-html {
    line-height: 1.6;
    color: #333;
}

.animal-description-html p {
    margin-bottom: 1rem;
}

.animal-description-html div {
    margin-bottom: 0.75rem;
}

.animal-description-html strong,
.animal-description-html b {
    font-weight: 600;
    color: #212529;
}

.animal-description-html em,
.animal-description-html i {
    font-style: italic;
}

.animal-description-html h1,
.animal-description-html h2,
.animal-description-html h3,
.animal-description-html h4,
.animal-description-html h5,
.animal-description-html h6 {
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    font-weight: 600;
    color: #007bff;
}

.animal-description-html ul,
.animal-description-html ol {
    margin-left: 1.5rem;
    margin-bottom: 1rem;
}

.animal-description-html li {
    margin-bottom: 0.25rem;
}

.animal-description-html blockquote {
    border-left: 4px solid #007bff;
    padding-left: 1rem;
    margin: 1rem 0;
    font-style: italic;
    background-color: #f8f9fa;
    padding: 1rem;
    border-radius: 4px;
}

/* Ensure proper spacing and readability */
.animal-description-html > *:first-child {
    margin-top: 0;
}

.animal-description-html > *:last-child {
    margin-bottom: 0;
}