/* Puppy Detail Section */
.puppy-detail-section {
    padding: 4rem 2rem;
    padding-top: calc(var(--header-height, 80px) + 4rem);
    background-color: #ffffff;
    min-height: calc(100vh - var(--header-height, 80px));
}

@media (min-width: 1440px) {
    .puppy-detail-section {
        padding: 5rem 3rem;
        padding-top: calc(var(--header-height, 80px) + 5rem);
    }
}

@media (min-width: 1920px) {
    .puppy-detail-section {
        padding: 6rem 4rem;
        padding-top: calc(var(--header-height, 80px) + 6rem);
    }
}

.puppy-detail-container {
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    padding: 0 2rem;
    display: flex;
    flex-direction: column;
    gap: 3rem;
}

.puppy-detail-content-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: start;
    min-height: 500px;
}

@media (min-width: 1440px) {
    .puppy-detail-container {
        max-width: 1400px;
        gap: 4rem;
        padding: 0 3rem;
    }

    .puppy-detail-content-wrapper {
        gap: 5rem;
    }
}

@media (min-width: 1920px) {
    .puppy-detail-container {
        max-width: 1600px;
        gap: 5rem;
        padding: 0 4rem;
    }

    .puppy-detail-content-wrapper {
        gap: 6rem;
    }
}

.puppy-detail-content {
    opacity: 0;
    transform: translateX(-30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-self: start;
    order: 1;
}

.puppy-detail-content.animated {
    opacity: 1;
    transform: translateX(0);
}

.puppy-detail-title {
    font-size: 3rem;
    font-weight: bold;
    color: #2c2c2c;
    margin: 0;
    line-height: 1.2;
    text-align: center;
    width: 100%;
}

@media (min-width: 1440px) {
    .puppy-detail-title {
        font-size: 3.5rem;
    }
}

.puppy-detail-info {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 2rem;
}

.puppy-detail-parents {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding: 1rem;
    background-color: #f8f8f8;
    border-radius: 8px;
    border-left: 4px solid #2F7F7A;
}

.parent-info {
    font-size: 1rem;
    color: #666;
    line-height: 1.6;
}

.puppy-detail-date {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #2F7F7A;
    font-size: 1rem;
    padding: 0.75rem;
    background-color: #f8f8f8;
    border-radius: 8px;
    border-left: 4px solid #2F7F7A;
}

.puppy-detail-date svg {
    flex-shrink: 0;
}

/* Puppies List */
.puppies-list {
    margin-bottom: 2rem;
}

.puppies-list-title {
    font-size: 1.5rem;
    font-weight: bold;
    color: #2c2c2c;
    margin-bottom: 1.5rem;
}

.puppies-table {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
    background-color: #ffffff;
}

.puppies-table-header {
    display: grid;
    grid-template-columns: 1fr 1.5fr 1fr;
    gap: 1rem;
    padding: 1rem;
    background-color: #2F7F7A;
    color: #ffffff !important;
    font-weight: 700;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.puppies-table-header > * {
    color: #ffffff !important;
}

.puppy-row {
    display: grid;
    grid-template-columns: 1fr 1.5fr 1fr;
    gap: 1rem;
    padding: 1rem;
    border-top: 1px solid #e0e0e0;
    transition: background-color 0.2s ease;
}

.puppy-row:hover {
    background-color: #f8f8f8;
}

.puppy-row:first-child {
    border-top: none;
}

.puppy-col-gender,
.puppy-col-colour,
.puppy-col-availability {
    display: flex;
    align-items: center;
    font-size: 0.95rem;
    color: #666;
}

.availability-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: capitalize;
}

.availability-available {
    background-color: #d4edda;
    color: #155724;
}

.availability-reserved {
    background-color: #fff3cd;
    color: #856404;
}

.availability-sold {
    background-color: #f8d7da;
    color: #721c24;
}

.puppy-detail-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: auto;
}

.btn {
    display: inline-block;
    padding: 0.75rem 2rem;
    background-color: #2F7F7A;
    color: #ffffff;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    transition: background-color 0.3s;
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn:hover {
    background-color: #5FA5A0;
}

.btn-secondary {
    background-color: #f0f0f0;
    color: #2c2c2c;
}

.btn-secondary:hover {
    background-color: #e0e0e0;
}

.btn-primary {
    background-color: #2F7F7A;
    color: #ffffff;
}

.btn-primary:hover {
    background-color: #5FA5A0;
}

/* Carousel Section */
.puppy-detail-carousel {
    opacity: 0;
    transform: translateX(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
    order: 2;
}

.puppy-detail-carousel.animated {
    opacity: 1;
    transform: translateX(0);
}

.carousel-container {
    position: relative;
    width: 100%;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 8px 30px rgba(0,0,0,0.12);
    background-color: #ffffff;
}

.carousel-wrapper {
    position: relative;
    width: 100%;
    padding-bottom: 75%; /* 4:3 aspect ratio */
    overflow: hidden;
}

.carousel-track {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform;
}

.carousel-slide {
    min-width: 100%;
    width: 100%;
    height: 100%;
    flex-shrink: 0;
    opacity: 0;
    transition: opacity 0.5s ease;
    position: relative;
}

.carousel-slide.active {
    opacity: 1;
}

.carousel-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Carousel Buttons */
.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(255, 255, 255, 0.9);
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s ease;
    color: #2c2c2c;
}

.carousel-btn:hover {
    background-color: #2F7F7A;
    color: #ffffff;
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.carousel-btn:active {
    transform: translateY(-50%) scale(0.95);
}

.carousel-btn-prev {
    left: 15px;
}

.carousel-btn-next {
    right: 15px;
}

.carousel-btn svg {
    width: 24px;
    height: 24px;
}

/* Carousel Indicators */
.carousel-indicators {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 10;
}

.carousel-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid #ffffff;
    background-color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
}

.carousel-indicator:hover {
    background-color: rgba(255, 255, 255, 0.8);
    transform: scale(1.2);
}

.carousel-indicator.active {
    background-color: #2F7F7A;
    border-color: #2F7F7A;
    transform: scale(1.3);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .puppy-detail-section {
        padding: 3rem 2rem;
        padding-top: calc(var(--header-height, 80px) + 3rem);
    }

    .puppy-detail-container {
        gap: 2rem;
    }

    .puppy-detail-content-wrapper {
        gap: 3rem;
    }

    .puppy-detail-title {
        font-size: 2.5rem;
    }
}

@media (max-width: 768px) {
    .puppy-detail-section {
        padding: 3rem 1.5rem;
        padding-top: calc(var(--header-height, 80px) + 3rem);
    }

    .puppy-detail-container {
        gap: 2rem;
        padding: 0 1rem;
    }

    .puppy-detail-content-wrapper {
        grid-template-columns: 1fr;
        gap: 2.5rem;
        min-height: auto;
    }

    .puppy-detail-content {
        transform: translateY(30px) !important;
        order: 2;
    }

    .puppy-detail-content.animated {
        transform: translateY(0) !important;
    }

    .puppy-detail-carousel {
        transform: translateY(30px) !important;
        order: 1;
    }

    .puppy-detail-carousel.animated {
        transform: translateY(0) !important;
    }

    .puppy-detail-title {
        font-size: 2rem;
    }

    .puppies-table-header,
    .puppy-row {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }

    .puppies-table-header {
        display: none;
    }

    .puppy-row {
        border-top: 1px solid #e0e0e0;
        padding: 1rem;
    }

    .puppy-col-gender::before {
        content: 'Gender: ';
        font-weight: 600;
        color: #2c2c2c;
        margin-right: 0.5rem;
    }

    .puppy-col-colour::before {
        content: 'Colour: ';
        font-weight: 600;
        color: #2c2c2c;
        margin-right: 0.5rem;
    }

    .puppy-col-availability::before {
        content: 'Availability: ';
        font-weight: 600;
        color: #2c2c2c;
        margin-right: 0.5rem;
    }

    .puppy-detail-actions {
        flex-direction: column;
    }

    .btn {
        width: 100%;
        text-align: center;
    }

    .carousel-btn {
        width: 40px;
        height: 40px;
    }

    .carousel-btn-prev {
        left: 10px;
    }

    .carousel-btn-next {
        right: 10px;
    }

    .carousel-btn svg {
        width: 20px;
        height: 20px;
    }

    .carousel-indicators {
        bottom: 15px;
    }

    .carousel-indicator {
        width: 10px;
        height: 10px;
    }
}

@media (max-width: 480px) {
    .puppy-detail-section {
        padding: 2rem 1rem;
        padding-top: calc(var(--header-height, 80px) + 2rem);
    }

    .puppy-detail-container {
        gap: 2rem;
        padding: 0;
    }

    .puppy-detail-title {
        font-size: 1.75rem;
    }

    .carousel-btn {
        width: 35px;
        height: 35px;
    }

    .carousel-btn-prev {
        left: 8px;
    }

    .carousel-btn-next {
        right: 8px;
    }

    .carousel-btn svg {
        width: 18px;
        height: 18px;
    }

    .carousel-indicators {
        bottom: 12px;
        gap: 8px;
    }

    .carousel-indicator {
        width: 8px;
        height: 8px;
    }
}

/* Touch-friendly improvements */
@media (hover: none) and (pointer: coarse) {
    .carousel-btn {
        min-width: 44px;
        min-height: 44px;
    }
}

