/* ============================================
   GETTIC - STYLE.CSS (Premium)
   Ana stil dosyası
   ============================================ */

/* ============ DEĞİŞKENLER ============ */
:root {
    /* Renkler */
    --bg-primary: #0a0a0f;
    --bg-secondary: #12121a;
    --bg-tertiary: #1a1a24;
    --bg-hover: #22222e;
    --bg-active: #2a2a38;

    --text-primary: #f4f4f6;
    --text-secondary: #a1a1b0;
    --text-muted: #6b6b7b;
    --text-inverse: #0a0a0f;

    --accent: #7c3aed;
    --accent-hover: #8b5cf6;
    --accent-light: #a78bfa;
    --accent-dark: #6d28d9;

    --online: #10b981;
    --offline: #6b7280;
    --busy: #ef4444;
    --away: #f59e0b;

    --border: #1f1f2e;
    --border-light: #2a2a3a;

    /* Gölgeler */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
    --shadow-xl: 0 20px 60px rgba(0, 0, 0, 0.6);
    --shadow-glow: 0 0 20px rgba(124, 58, 237, 0.4);
    --shadow-glow-strong: 0 8px 25px rgba(124, 58, 237, 0.5);

    /* Geçişler */
    --transition-fast: 0.15s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 0.6s cubic-bezier(0.4, 0, 0.2, 1);

    /* Spacing */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;

    /* Z-index */
    --z-dropdown: 50;
    --z-modal: 100;
    --z-toast: 1000;
    --z-tooltip: 1100;
}

/* ============ RESET ============ */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    min-height: 100vh;
}

img,
video,
svg {
    display: block;
    max-width: 100%;
    height: auto;
}

button {
    font-family: inherit;
}

input,
textarea,
select {
    font-family: inherit;
}

/* ============ SCROLLBAR ============ */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
    background: var(--bg-tertiary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent);
}

* {
    scrollbar-width: thin;
    scrollbar-color: var(--bg-tertiary) var(--bg-primary);
}

/* Gizli scrollbar (isteğe bağlı) */
.hidden-scrollbar::-webkit-scrollbar {
    display: none;
}
.hidden-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* ============ SEÇİM ============ */
::selection {
    background: var(--accent);
    color: white;
}

/* ============ AUTOFILL ============ */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus {
    -webkit-box-shadow: 0 0 0 1000px var(--bg-tertiary) inset;
    -webkit-text-fill-color: var(--text-primary);
    transition: background-color 5000s ease-in-out 0s;
}

/* ============ FOCUS ============ */
:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* ============ UTILITIES ============ */

/* Text */
.text-primary { color: var(--text-primary); }
.text-secondary { color: var(--text-secondary); }
.text-muted { color: var(--text-muted); }
.text-accent { color: var(--accent); }
.text-online { color: var(--online); }
.text-busy { color: var(--busy); }
.text-away { color: var(--away); }

/* Background */
.bg-primary { background-color: var(--bg-primary); }
.bg-secondary { background-color: var(--bg-secondary); }
.bg-tertiary { background-color: var(--bg-tertiary); }

/* Layout */
.flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
}
.flex-between {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.flex-start {
    display: flex;
    align-items: center;
    justify-content: flex-start;
}
.flex-end {
    display: flex;
    align-items: center;
    justify-content: flex-end;
}
.flex-col-center {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* Text utils */
.truncate {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.line-clamp-1,
.line-clamp-2,
.line-clamp-3 {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.line-clamp-1 { -webkit-line-clamp: 1; line-clamp: 1; }
.line-clamp-2 { -webkit-line-clamp: 2; line-clamp: 2; }
.line-clamp-3 { -webkit-line-clamp: 3; line-clamp: 3; }

/* Accessibility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Pointer */
.pointer-events-none { pointer-events: none; }
.pointer-events-auto { pointer-events: auto; }
.cursor-pointer { cursor: pointer; }
.cursor-not-allowed { cursor: not-allowed; }

/* ============ SHIMMER BUTON ============ */
.shimmer-button {
    position: relative;
    overflow: hidden;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--accent), var(--accent-dark));
    color: white;
    font-weight: 600;
    font-family: inherit;
    padding: 14px 28px;
    border-radius: var(--radius-md);
    border: none;
    cursor: pointer;
    transition: all var(--transition-normal);
    box-shadow: 0 4px 15px rgba(124, 58, 237, 0.3);
    text-decoration: none;
    white-space: nowrap;
    z-index: 1;
}

.shimmer-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 60%;
    height: 100%;
    background: linear-gradient(120deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transform: skewX(-25deg);
    animation: shimmer 3s infinite;
    z-index: -1;
}

.shimmer-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(124, 58, 237, 0.5);
}

.shimmer-button:active {
    transform: translateY(0) scale(0.98);
}

.shimmer-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* ============ GLASSMORPHISM ============ */
.glass {
    background: rgba(18, 18, 26, 0.7);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.glass-strong {
    background: rgba(10, 10, 15, 0.85);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
}

/* ============ GRADIENT TEXT ============ */
.gradient-text {
    background: linear-gradient(135deg, var(--accent-light), var(--accent), var(--accent-dark));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    background-size: 200% 200%;
    animation: gradientShift 3s ease infinite;
}

.gradient-text-purple {
    background: linear-gradient(135deg, #a78bfa, #7c3aed, #6d28d9);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* ============ MESAJ BALONLARI ============ */
.message-bubble-premium {
    max-width: 70%;
    padding: 12px 18px;
    border-radius: 18px;
    position: relative;
    word-wrap: break-word;
    overflow-wrap: break-word;
    transition: all 0.2s ease;
    animation: fadeIn 0.3s ease-out;
}

.message-bubble-premium.sent {
    background: linear-gradient(135deg, var(--accent), var(--accent-dark));
    color: white;
    border-bottom-right-radius: 4px;
    box-shadow: 0 4px 15px rgba(124, 58, 237, 0.3);
}

.message-bubble-premium.received {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border-bottom-left-radius: 4px;
    border: 1px solid var(--border);
}

.message-bubble-premium:hover {
    transform: translateY(-2px);
}

/* ============ AVATAR ============ */
.avatar-premium {
    border-radius: 50%;
    object-fit: cover;
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: white;
    background: linear-gradient(135deg, var(--accent), var(--accent-dark));
    box-shadow: 0 4px 15px rgba(124, 58, 237, 0.3);
    flex-shrink: 0;
    user-select: none;
}

.avatar-online::after {
    content: '';
    position: absolute;
    bottom: 2px;
    right: 2px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--online);
    border: 2px solid var(--bg-secondary);
    box-shadow: 0 0 10px var(--online);
}

/* ============ TOAST ============ */
.toast-premium {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 16px 24px;
    border-radius: var(--radius-lg);
    color: white;
    font-weight: 500;
    font-size: 14px;
    box-shadow: var(--shadow-xl);
    display: flex;
    align-items: center;
    gap: 12px;
    animation: slideInRight 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: var(--z-toast);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    max-width: 400px;
}

.toast-success { background: linear-gradient(135deg, var(--online), #059669); }
.toast-error { background: linear-gradient(135deg, var(--busy), #dc2626); }
.toast-warning { background: linear-gradient(135deg, var(--away), #d97706); }
.toast-info { background: linear-gradient(135deg, var(--accent), var(--accent-dark)); }

/* ============ SPINNER ============ */
.spinner-premium {
    width: 40px;
    height: 40px;
    border: 3px solid var(--bg-tertiary);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.spinner-sm {
    width: 20px;
    height: 20px;
    border-width: 2px;
}

.spinner-lg {
    width: 60px;
    height: 60px;
    border-width: 4px;
}

/* ============ TYPING ============ */
.typing-indicator-premium {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 12px 16px;
    background: var(--bg-tertiary);
    border-radius: 18px;
    width: fit-content;
    border: 1px solid var(--border);
}

.typing-dot-premium {
    width: 7px;
    height: 7px;
    background: var(--accent-light);
    border-radius: 50%;
    animation: typingBounce 1.4s infinite;
}

.typing-dot-premium:nth-child(2) { animation-delay: 0.2s; }
.typing-dot-premium:nth-child(3) { animation-delay: 0.4s; }

/* ============ GLOW EFEKTİ ============ */
.glow-effect {
    position: relative;
    isolation: isolate;
}

.glow-effect::after {
    content: '';
    position: absolute;
    inset: -2px;
    background: linear-gradient(135deg, var(--accent), var(--accent-dark));
    border-radius: inherit;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s ease;
    filter: blur(10px);
}

.glow-effect:hover::after {
    opacity: 0.6;
}

/* ============ HOVER EFEKTLERİ ============ */
.hover-lift {
    transition: transform var(--transition-normal), box-shadow var(--transition-normal);
    will-change: transform;
}

.hover-lift:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
}

.hover-scale {
    transition: transform var(--transition-normal);
    will-change: transform;
}

.hover-scale:hover {
    transform: scale(1.05);
}

.hover-opacity {
    transition: opacity var(--transition-normal);
}

.hover-opacity:hover {
    opacity: 0.8;
}

/* ============ ANİMASYON SINIFLARI ============ */
.fade-in { animation: fadeIn 0.5s ease-out; }
.fade-in-fast { animation: fadeIn 0.2s ease-out; }
.slide-up { animation: slideUp 0.5s ease-out; }
.slide-down { animation: slideDown 0.5s ease-out; }
.scale-in { animation: scaleIn 0.4s ease-out; }
.float { animation: float 3s ease-in-out infinite; }
.glow { animation: glow 2s infinite; }
.pulse { animation: pulse 2s infinite; }

/* ============ GRADIENT BORDER ============ */
.gradient-border {
    position: relative;
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
}

.gradient-border::before {
    content: '';
    position: absolute;
    inset: 0;
    padding: 1px;
    border-radius: inherit;
    background: linear-gradient(135deg, var(--accent), transparent, var(--accent));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

/* ============ NOISE TEXTURE ============ */
.noise {
    position: relative;
}

.noise::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.05'/%3E%3C/svg%3E");
    pointer-events: none;
    opacity: 0.4;
}

/* ============ RESPONSIVE ============ */
@media (max-width: 768px) {
    .message-bubble-premium {
        max-width: 85%;
    }

    .toast-premium {
        top: 12px;
        right: 12px;
        left: 12px;
        max-width: none;
    }
}

@media (max-width: 480px) {
    .message-bubble-premium {
        max-width: 90%;
        padding: 10px 14px;
    }

    .shimmer-button {
        padding: 12px 20px;
        font-size: 14px;
    }
}

/* ============ ERİŞİLEBİLİRLİK ============ */
@media (prefers-reduced-motion: reduce) {
    /* Sonsuz animasyonları durdur */
    .float,
    .glow,
    .pulse,
    .shimmer-button::before,
    .gradient-text,
    .typing-dot-premium,
    .spinner-premium {
        animation: none !important;
    }

    /* Giriş animasyonlarını hızlı yap */
    .fade-in,
    .slide-up,
    .slide-down,
    .scale-in,
    .message-bubble-premium {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }

    /* Transition'ları sıfırla */
    *,
    *::before,
    *::after {
        transition-duration: 0.01ms !important;
    }
}

/* ============ KEYFRAMES (Sadece burada) ============ */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-30px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slideInRight {
    from { opacity: 0; transform: translateX(100%); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes scaleIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

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

@keyframes spin {
    to { transform: rotate(360deg); }
}

@keyframes shimmer {
    0% { left: -100%; }
    20% { left: 100%; }
    100% { left: 100%; }
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

@keyframes glow {
    0%, 100% { box-shadow: 0 0 20px rgba(124, 58, 237, 0.3); }
    50% { box-shadow: 0 0 40px rgba(124, 58, 237, 0.6); }
}

@keyframes typingBounce {
    0%, 60%, 100% { transform: translateY(0); }
    30% { transform: translateY(-6px); }
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* ============ INPUT FIX ============ */
input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="file"]),
textarea,
select {
    background-color: #1a1a24 !important;
    color: #f4f4f6 !important;
    border: 1.5px solid #1f1f2e !important;
    border-radius: 12px !important;
    padding: 12px 16px !important;
    font-family: inherit !important;
    font-size: 14px !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    width: 100% !important;
    outline: none !important;
    box-shadow: none !important;
}

input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="file"]):hover,
textarea:hover,
select:hover {
    border-color: #2a2a3a !important;
}

input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="file"]):focus,
textarea:focus,
select:focus {
    border-color: #7c3aed !important;
    background-color: #12121a !important;
    box-shadow: 0 0 0 4px rgba(124, 58, 237, 0.15) !important;
}

input::placeholder,
textarea::placeholder {
    color: #6b6b7b !important;
    opacity: 1 !important;
}

/* Autofill fix */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus {
    -webkit-box-shadow: 0 0 0 1000px #1a1a24 inset !important;
    -webkit-text-fill-color: #f4f4f6 !important;
    caret-color: #f4f4f6 !important;
    transition: background-color 5000s ease-in-out 0s !important;
}

/* File input */
input[type="file"] {
    color: #f4f4f6 !important;
    background: #1a1a24 !important;
    border: 1.5px solid #1f1f2e !important;
    border-radius: 12px !important;
    padding: 12px !important;
    cursor: pointer !important;
}

input[type="file"]::file-selector-button {
    background: #7c3aed;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 8px;
    margin-right: 12px;
    cursor: pointer;
    font-weight: 600;
    font-family: inherit;
    transition: background 0.3s;
}

input[type="file"]::file-selector-button:hover {
    background: #8b5cf6;
}

/* Select arrow */
select {
    appearance: none !important;
    -webkit-appearance: none !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23a1a1b0'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 14px center !important;
    background-size: 18px !important;
    padding-right: 42px !important;
    cursor: pointer !important;
}

select option {
    background: #12121a !important;
    color: #f4f4f6 !important;
}

/* Checkbox & Radio */
input[type="checkbox"],
input[type="radio"] {
    width: 18px !important;
    height: 18px !important;
    accent-color: #7c3aed !important;
    cursor: pointer !important;
}
