/* Custom styles for ZeroGPT */

.detector-card {
    scroll-margin-top: 6rem;
}

.detector-textarea-wrapper {
    transition: box-shadow 150ms ease, border-color 150ms ease, background-color 150ms ease;
}

.detector-textarea {
    outline: none;
}

.detector-textarea:focus-visible {
    outline: none;
}

/* Toast Notifications */
#toast-container {
    perspective: 1000px;
}

.toast {
    animation: toast-in 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
    pointer-events: auto;
    box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
}

.toast.removing {
    animation: toast-out 0.3s ease forwards;
}

@keyframes toast-in {
    from {
        transform: translateY(20px) scale(0.95);
        opacity: 0;
    }

    to {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

@keyframes toast-out {
    to {
        transform: translateX(20%) scale(0.95);
        opacity: 0;
    }
}

/* Mega Menu — Premium Redesign */
.mega-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(8px);
    padding-top: 0.75rem;
    width: 560px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease, transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    pointer-events: none;
    z-index: 100;
}

.group:hover .mega-menu {
    opacity: 1 !important;
    visibility: visible !important;
    transform: translateX(-50%) translateY(0) !important;
    pointer-events: auto !important;
}

.mega-menu-container {
    background-color: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 1rem;
    box-shadow: 0 12px 40px -8px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(0, 0, 0, 0.03);
    padding: 0.375rem;
    overflow: hidden;
}

.dark .mega-menu-container {
    background-color: #0f172a;
    border-color: #1e293b;
    box-shadow: 0 12px 40px -8px rgba(0, 0, 0, 0.5);
}

.mega-menu-item {
    display: flex !important;
    align-items: center !important;
    gap: 0.875rem !important;
    padding: 0.625rem 0.75rem !important;
    border-radius: 0.625rem !important;
    transition: background-color 0.15s ease !important;
    text-decoration: none !important;
    border-left: 2px solid transparent !important;
}

.mega-menu-item:hover {
    background-color: #f8fafc !important;
    border-left-color: #3b82f6 !important;
}

.dark .mega-menu-item:hover {
    background-color: #1e293b !important;
    border-left-color: #3b82f6 !important;
}

.mega-menu-item .icon-wrapper {
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.mega-menu-item:hover .icon-wrapper {
    transform: scale(1.08);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.dark .mega-menu-item:hover .icon-wrapper {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.mega-menu-item .content-wrapper {
    display: flex;
    flex-direction: column;
    gap: 0.0625rem;
}

.mega-menu-item .title {
    font-size: 0.8125rem;
    font-weight: 600;
    color: #0f172a;
    letter-spacing: -0.01em;
    transition: color 0.15s ease;
}

.dark .mega-menu-item .title {
    color: #f1f5f9;
}

.mega-menu-item:hover .title {
    color: #3b82f6;
}

.mega-menu-item .desc {
    font-size: 0.6875rem;
    color: #94a3b8;
    line-height: 1.4;
    letter-spacing: 0.01em;
}

.dark .mega-menu-item .desc {
    color: #64748b;
}

.mega-menu .bottom-bar {
    margin: 0.25rem 0.375rem 0.375rem;
    padding: 0.625rem 0.75rem;
    background-color: #f8fafc;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-top: none;
}

.dark .mega-menu .bottom-bar {
    background-color: #1e293b;
}