/* TaskFlow — Custom Styles
 * Tailwind CDN üzerine binen ufak iyileştirmeler.
 */

/* Alpine cloak — Alpine yüklenirken titremesin */
[x-cloak] { display: none !important; }

/* Daha tatlı seçim rengi */
::selection {
    background: #6366f1;
    color: #fff;
}

/* Daha güzel scrollbar */
::-webkit-scrollbar          { width: 10px; height: 10px; }
::-webkit-scrollbar-track    { background: transparent; }
::-webkit-scrollbar-thumb    { background: #cbd5e1; border-radius: 10px; border: 2px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-thumb:hover { background: #94a3b8; background-clip: padding-box; border: 2px solid transparent; }

.dark ::-webkit-scrollbar-thumb       { background: #475569; background-clip: padding-box; border: 2px solid transparent; }
.dark ::-webkit-scrollbar-thumb:hover { background: #64748b; background-clip: padding-box; border: 2px solid transparent; }

/* Line clamp helper'ları (Tailwind 3'te zaten var ama Tailwind play CDN'inde garanti) */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Sürükleme imleci */
[draggable="true"] { cursor: grab; }
[draggable="true"]:active { cursor: grabbing; }

/* Border-3 utility (Tailwind play CDN'inde standart border-2 var, biz 3'ü ekliyoruz) */
.border-3 { border-width: 3px; }

/* Toast wrapper */
#tf-toasts {
    position: fixed;
    bottom: 1rem;
    right: 1rem;
    z-index: 100;
    display: flex;
    flex-direction: column-reverse;
    gap: 0.5rem;
    pointer-events: none;
}
.tf-toast {
    background: white;
    color: #0f172a;
    padding: 0.75rem 1rem;
    border-radius: 0.75rem;
    box-shadow: 0 10px 25px -5px rgba(0,0,0,0.1), 0 8px 10px -6px rgba(0,0,0,0.1);
    border: 1px solid #e2e8f0;
    min-width: 220px;
    max-width: 360px;
    font-size: 0.875rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    animation: tfSlideIn 0.25s ease-out;
    pointer-events: auto;
}
.tf-toast.success { border-left: 4px solid #10b981; }
.tf-toast.error   { border-left: 4px solid #f43f5e; color: #be123c; }
.tf-toast.info    { border-left: 4px solid #6366f1; }
.tf-toast.fade-out { animation: tfFadeOut 0.25s ease-in forwards; }

.dark .tf-toast { background: #1e293b; color: #f1f5f9; border-color: #334155; }
.dark .tf-toast.error { color: #fda4af; }

@keyframes tfSlideIn {
    from { opacity: 0; transform: translateY(20px) scale(0.96); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes tfFadeOut {
    to { opacity: 0; transform: translateY(20px) scale(0.96); }
}

/* Skeleton pulse */
@keyframes tfPulse {
    0%, 100% { opacity: 1; }
    50%      { opacity: 0.5; }
}
.animate-pulse { animation: tfPulse 1.8s cubic-bezier(0.4, 0, 0.6, 1) infinite; }

/* Kanban kart hover effect */
.cursor-pointer:hover { transition-duration: 200ms; }

/* Bildirim çanı badge çakışmasını önle */
kbd { font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; }

/* Daha akıcı modal transition */
.animate-fade-in   { animation: fadeIn 0.18s ease-out; }
.animate-slide-up  { animation: slideUp 0.22s cubic-bezier(0.16, 1, 0.3, 1); }
@keyframes fadeIn  { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideUp { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }

/* Tooltip durağan kalsın */
[title] { position: relative; }

/* Focus accessibility */
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
    outline: 2px solid #6366f1;
    outline-offset: 2px;
}

/* Smooth transitions globally */
html {
    scroll-behavior: smooth;
}
body {
    transition: background-color 0.2s ease, color 0.2s ease;
}
