/* Modal styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1050;
    transition: all 0.3s ease;
}

/* Specific z-index for modals that need to appear on top of others */
#resizeSettingsModal {
    z-index: 1060; /* Higher z-index to ensure it appears on top of other modals */
}


#pdf-settings-modal {
    z-index: 1070; /* Highest z-index to ensure it appears on top of other modals */
}

#navigationConfirmModal {
    z-index: 1070; /* Highest z-index for navigation confirmation */
}

.modal.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.modal:not(.hidden) {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background-color: white;
    border-radius: 0.5rem;
    padding: 2rem;
    width: 100%;
    max-width: 700px;
    transform: translateY(0);
    transition: all 0.3s ease;
    box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.175);
}

/* Modal header styling */
.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

/* Ensure even spacing in the generate image modal */
#generateImageModal .prompt-column {
    padding: 0 0.5rem;
}

.modal.hidden .modal-content {
    transform: translateY(20px);
}

.modal-open {
    overflow: hidden;
}

#etsyListingModal {
    transition: opacity 0.3s ease;
}

#etsyListingModal.hidden {
    opacity: 0;
    pointer-events: none;
}

#etsyListingModal .bg-white {
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

#etsyListingModal:not(.hidden) .bg-white {
    transform: translateY(0);
}

#etsyListingModal.hidden .bg-white {
    transform: translateY(20px);
}

#etsyListingContent {
    max-height: 60vh;
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: #4b5563;
}

/* Button animations */
.animate-pulse {
    animation: pulse 1.5s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

/* Copy button success animation */
.copy-success {
    background-color: #10B981 !important;
    transition: background-color 0.3s ease;
}

/* Scrollbar styling for the listing content */
#etsyListingContent::-webkit-scrollbar {
    width: 8px;
}

#etsyListingContent::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

#etsyListingContent::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 10px;
}

#etsyListingContent::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Policy modal styles */
.policy-content {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: #4b5563;
    padding: 1rem 0;
}

.policy-content h1 {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: #1f2937;
}

.policy-content h2 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: #1f2937;
}

.policy-content h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    color: #1f2937;
}

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

.policy-content ul {
    list-style-type: disc;
    margin-left: 1.5rem;
    margin-bottom: 1rem;
}

.policy-content li {
    margin-bottom: 0.5rem;
}

/* Scrollbar styling for the policy content */
.policy-content::-webkit-scrollbar {
    width: 8px;
}

.policy-content::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.policy-content::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 10px;
}

.policy-content::-webkit-scrollbar-thumb:hover {
    background: #555;
}