/* ============================================================
   StudySync — Premium Animated CSS (ORİJİNAL KORUMALI)
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;700;800;900&display=swap');

/* ---- CSS Variables (Pink Light - default) ---- */
:root {
    --c1: #ff5fa0;
    --c2: #ff85bc;
    --c3: #ffb3d1;
    --bg: #fff0f5;
    --bg2: #ffe0ed;
    --card: rgba(255, 255, 255, 0.82);
    --sidebar-bg: rgba(255, 240, 248, 0.96);
    --text: #3a1a28;
    --text2: #7a4060;
    --muted: #b07090;
    --border: rgba(255, 95, 160, 0.18);
    --shadow: 0 8px 32px rgba(255, 95, 160, 0.18);
    --glow: rgba(255, 95, 160, 0.35);
    --active-bg: rgba(255, 95, 160, 0.12);
    --success: #28d99c;
    --danger: #ff4d4d;
    --warning: #ffb347;
    --r: 18px;
}

html[data-color="pink"][data-theme="dark"] { --c1: #ff5fa0; --c2: #ff85bc; --c3: #6a1535; --bg: #120009; --bg2: #200014; --card: rgba(38, 5, 22, 0.88); --sidebar-bg: rgba(20, 2, 14, 0.97); --text: #ffe0ec; --text2: #ffaacb; --muted: #7a4060; --border: rgba(255, 95, 160, 0.15); --shadow: 0 8px 32px rgba(0, 0, 0, 0.5); --glow: rgba(255, 95, 160, 0.25); --active-bg: rgba(255, 95, 160, 0.12); }
html[data-color="purple"][data-theme="light"] { --c1: #8b5cf6; --c2: #a78bfa; --c3: #ddd6fe; --bg: #f5f3ff; --bg2: #ede9fe; --card: rgba(255, 255, 255, 0.82); --sidebar-bg: rgba(245, 243, 255, 0.96); --text: #2e1060; --text2: #5b21b6; --muted: #7c6b9d; --border: rgba(139, 92, 246, 0.18); --shadow: 0 8px 32px rgba(139, 92, 246, 0.18); --glow: rgba(139, 92, 246, 0.35); --active-bg: rgba(139, 92, 246, 0.12); }
html[data-color="purple"][data-theme="dark"] { --c1: #a78bfa; --c2: #c4b5fd; --c3: #2e1065; --bg: #08031c; --bg2: #12063a; --card: rgba(18, 6, 55, 0.88); --sidebar-bg: rgba(8, 3, 28, 0.97); --text: #ede9fe; --text2: #c4b5fd; --muted: #5b4080; --border: rgba(167, 139, 250, 0.15); --shadow: 0 8px 32px rgba(0, 0, 0, 0.5); --glow: rgba(167, 139, 250, 0.25); --active-bg: rgba(167, 139, 250, 0.12); }
html[data-color="blue"][data-theme="light"] { --c1: #3b82f6; --c2: #60a5fa; --c3: #dbeafe; --bg: #eff6ff; --bg2: #dbeafe; --card: rgba(255, 255, 255, 0.82); --sidebar-bg: rgba(239, 246, 255, 0.96); --text: #1e3a5f; --text2: #1d4ed8; --muted: #5a90c0; --border: rgba(59, 130, 246, 0.18); --shadow: 0 8px 32px rgba(59, 130, 246, 0.18); --glow: rgba(59, 130, 246, 0.35); --active-bg: rgba(59, 130, 246, 0.12); }
html[data-color="blue"][data-theme="dark"] { --c1: #60a5fa; --c2: #93c5fd; --c3: #0a1e42; --bg: #030a18; --bg2: #071228; --card: rgba(7, 18, 45, 0.88); --sidebar-bg: rgba(3, 10, 24, 0.97); --text: #dbeafe; --text2: #93c5fd; --muted: #3a608a; --border: rgba(96, 165, 250, 0.15); --shadow: 0 8px 32px rgba(0, 0, 0, 0.5); --glow: rgba(96, 165, 250, 0.25); --active-bg: rgba(96, 165, 250, 0.12); }
html[data-color="green"][data-theme="light"] { --c1: #10b981; --c2: #34d399; --c3: #d1fae5; --bg: #ecfdf5; --bg2: #d1fae5; --card: rgba(255, 255, 255, 0.82); --sidebar-bg: rgba(236, 253, 245, 0.96); --text: #0f3028; --text2: #047857; --muted: #3a8060; --border: rgba(16, 185, 129, 0.18); --shadow: 0 8px 32px rgba(16, 185, 129, 0.18); --glow: rgba(16, 185, 129, 0.35); --active-bg: rgba(16, 185, 129, 0.12); }
html[data-color="green"][data-theme="dark"] { --c1: #34d399; --c2: #6ee7b7; --c3: #042818; --bg: #01100a; --bg2: #031a10; --card: rgba(3, 20, 12, 0.88); --sidebar-bg: rgba(1, 10, 6, 0.97); --text: #d1fae5; --text2: #6ee7b7; --muted: #1a6040; --border: rgba(52, 211, 153, 0.15); --shadow: 0 8px 32px rgba(0, 0, 0, 0.5); --glow: rgba(52, 211, 153, 0.25); --active-bg: rgba(52, 211, 153, 0.12); }
html[data-color="orange"][data-theme="light"] { --c1: #f97316; --c2: #fb923c; --c3: #fed7aa; --bg: #fff7ed; --bg2: #ffedd5; --card: rgba(255, 255, 255, 0.82); --sidebar-bg: rgba(255, 247, 237, 0.96); --text: #3d1202; --text2: #c2410c; --muted: #a05030; --border: rgba(249, 115, 22, 0.18); --shadow: 0 8px 32px rgba(249, 115, 22, 0.18); --glow: rgba(249, 115, 22, 0.35); --active-bg: rgba(249, 115, 22, 0.12); }
html[data-color="orange"][data-theme="dark"] { --c1: #fb923c; --c2: #fdba74; --c3: #3d1200; --bg: #0f0500; --bg2: #1d0a00; --card: rgba(30, 8, 0, 0.88); --sidebar-bg: rgba(15, 5, 0, 0.97); --text: #fed7aa; --text2: #fdba74; --muted: #7a3010; --border: rgba(251, 146, 60, 0.15); --shadow: 0 8px 32px rgba(0, 0, 0, 0.5); --glow: rgba(251, 146, 60, 0.25); --active-bg: rgba(251, 146, 60, 0.12); }

/* ---- Base ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg);
    color: var(--text);
    min-height: 100vh;
    transition: background 0.5s, color 0.5s;
    overflow-x: hidden;
    position: relative;
}

/* ============================================================
   EKLENEN YENİ: ARKAPLAN BLOB ANİMASYONLARI
   ============================================================ */
.bg-animation {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    z-index: -1; overflow: hidden; pointer-events: none;
}
.blob {
    position: absolute; border-radius: 50%; filter: blur(100px);
    opacity: 0.25; animation: moveBlob 20s infinite alternate;
}
.blob-1 { width: 600px; height: 600px; background: var(--c1); top: -200px; left: -150px; }
.blob-2 { width: 500px; height: 500px; background: var(--c2); bottom: -150px; right: -100px; animation-delay: -5s; }
.blob-3 { width: 300px; height: 300px; background: var(--c3); top: 40%; left: 50%; animation-delay: -10s; }

@keyframes moveBlob {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(40px, 60px) scale(1.1); }
}

/* ---- Animated Gradient Background Orbs (Senin Orijinalin) ---- */
body::before, body::after {
    content: ''; position: fixed; border-radius: 50%; filter: blur(80px); z-index: 0; pointer-events: none;
    animation: orbFloat 14s ease-in-out infinite alternate;
}
body::before { width: 500px; height: 500px; background: radial-gradient(circle, var(--c1), transparent 70%); top: -150px; left: -150px; opacity: 0.18; }
body::after { width: 400px; height: 400px; background: radial-gradient(circle, var(--c2), transparent 70%); bottom: -100px; right: -100px; opacity: 0.15; animation-delay: -7s; }
@keyframes orbFloat { 0% { transform: translate(0, 0) scale(1); } 50% { transform: translate(40px, -60px) scale(1.12); } 100% { transform: translate(-30px, 30px) scale(0.9); } }

/* ---- Floating Sparkles (auth page) ---- */
.sparkle { position: fixed; pointer-events: none; z-index: 0; animation: sparklePop 3s ease-in-out infinite; }
.sparkle::before { content: '✦'; font-size: 1.2rem; color: var(--c1); opacity: 0.6; }
@keyframes sparklePop { 0%, 100% { transform: translateY(0) rotate(0deg); opacity: 0.4; } 50% { transform: translateY(-20px) rotate(20deg); opacity: 1; } }

/* ============================================================
   AUTH PAGE
   ============================================================ */
.auth-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; position: relative; overflow: hidden; }
.auth-bg-text { position: fixed; font-size: 28vw; font-weight: 900; color: var(--c1); opacity: 0.03; top: 50%; left: 50%; transform: translate(-50%, -50%); pointer-events: none; user-select: none; z-index: 0; white-space: nowrap; }
.auth-card { position: relative; z-index: 1; width: 100%; max-width: 420px; background: var(--card); border-radius: 28px; border: 1.5px solid var(--border); box-shadow: var(--shadow), 0 0 60px var(--glow); padding: 2.5rem; backdrop-filter: blur(20px); animation: popIn 0.7s cubic-bezier(0.175, 0.885, 0.32, 1.275) both; }
@keyframes popIn { from { opacity: 0; transform: scale(0.85) translateY(30px); } to { opacity: 1; transform: scale(1) translateY(0); } }

.auth-logo { text-align: center; margin-bottom: 2rem; }
.auth-logo .logo-icon { font-size: 3rem; display: inline-block; animation: logoBounce 2.5s ease-in-out infinite; filter: drop-shadow(0 0 12px var(--glow)); }
@keyframes logoBounce { 0%, 100% { transform: translateY(0) rotate(-5deg); } 50% { transform: translateY(-8px) rotate(5deg); } }
.auth-logo h1 { font-size: 2.4rem; font-weight: 900; background: linear-gradient(135deg, var(--c1), var(--c2)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; line-height: 1.1; }
.auth-logo p { color: var(--muted); font-size: 0.92rem; margin-top: 0.3rem; }

.auth-tabs { display: flex; gap: 0; margin-bottom: 1.8rem; background: var(--bg2); border-radius: 50px; padding: 4px; }
.auth-tab { flex: 1; padding: 10px; text-align: center; font-weight: 700; font-size: 0.9rem; border-radius: 50px; cursor: pointer; transition: all 0.3s ease; color: var(--muted); }
.auth-tab.active { background: linear-gradient(135deg, var(--c1), var(--c2)); color: white; box-shadow: 0 4px 15px var(--glow); }

.input-group { margin-bottom: 1.3rem; }
.input-group label { display: block; font-size: 0.88rem; font-weight: 600; color: var(--text2); margin-bottom: 6px; }
.input-group input, .input-group select { width: 100%; padding: 13px 16px; border-radius: 14px; border: 2px solid var(--border); background: var(--bg); color: var(--text); font-family: 'Outfit', sans-serif; font-size: 0.95rem; transition: all 0.3s ease; outline: none; }
.input-group input:focus, .input-group select:focus { border-color: var(--c1); box-shadow: 0 0 0 4px var(--glow); background: var(--card); }
.error-msg { background: rgba(255, 77, 77, 0.1); color: var(--danger); border-left: 4px solid var(--danger); padding: 10px 14px; border-radius: 10px; font-size: 0.85rem; margin-bottom: 1rem; animation: shake 0.4s ease; }
@keyframes shake { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 24px; border-radius: 14px; font-family: 'Outfit', sans-serif; font-weight: 700; font-size: 0.95rem; cursor: pointer; border: none; transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); text-decoration: none; position: relative; overflow: hidden; }
.btn-primary { background: linear-gradient(135deg, var(--c1), var(--c2)); color: white; box-shadow: 0 4px 18px var(--glow); }
.btn-primary:hover { transform: translateY(-3px) scale(1.04); box-shadow: 0 8px 28px var(--glow); }
.btn-primary:active { transform: scale(0.97); }
.btn-primary::before { content: ''; position: absolute; top: 0; left: -100%; width: 100%; height: 100%; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.25), transparent); transition: 0.5s; }
.btn-primary:hover::before { left: 100%; }
.btn-ghost { background: var(--bg2); color: var(--text); border: 1.5px solid var(--border); }
.btn-ghost:hover { background: var(--border); transform: translateY(-2px); }
.btn-danger { background: linear-gradient(135deg, #ff4d4d, #ff7070); color: white; box-shadow: 0 4px 14px rgba(255, 77, 77, 0.3); }
.btn-danger:hover { transform: translateY(-2px); }
.btn-sm { padding: 8px 16px; font-size: 0.82rem; border-radius: 10px; }
.btn-block { width: 100%; }

/* ============================================================
   LAYOUT
   ============================================================ */
.layout { display: flex; min-height: 100vh; position: relative; z-index: 1; }

/* ---- SIDEBAR ---- */
.sidebar {
    width: 260px; min-height: 100vh; position: fixed; top: 0; left: 0;
    background: var(--sidebar-bg); backdrop-filter: blur(24px); border-right: 1.5px solid var(--border);
    display: flex; flex-direction: column; padding: 1.8rem 1.2rem; z-index: 100;
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.08); transition: background 0.5s;
    
    /* EKLENEN: PC'de menünün aşağı kaymasını sağlar */
    overflow-y: auto; overflow-x: hidden;
}

/* Scrollbar şekillendirmesi */
.sidebar::-webkit-scrollbar { width: 6px; }
.sidebar::-webkit-scrollbar-thumb { background: var(--c3); border-radius: 10px; }

.sidebar-logo { display: flex; align-items: center; gap: 12px; margin-bottom: 2.5rem; padding: 0.5rem 0.8rem; }
.sidebar-logo .logo-emoji { font-size: 1.8rem; animation: logoBounce 3s ease-in-out infinite; filter: drop-shadow(0 0 8px var(--glow)); }
.sidebar-logo h2 { font-size: 1.4rem; font-weight: 900; background: linear-gradient(135deg, var(--c1), var(--c2)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }

.nav-section { font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1.5px; color: var(--muted); padding: 0 0.8rem; margin: 1rem 0 0.5rem; }
.nav-item { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-radius: 14px; text-decoration: none; color: var(--text2); font-weight: 600; font-size: 0.93rem; transition: all 0.25s ease; margin-bottom: 3px; position: relative; overflow: hidden; }
.nav-item .nav-icon { width: 32px; height: 32px; border-radius: 10px; background: var(--bg2); display: flex; align-items: center; justify-content: center; font-size: 0.95rem; transition: all 0.3s ease; flex-shrink: 0; }
.nav-item:hover { background: var(--bg2); color: var(--c1); transform: translateX(4px); }
.nav-item:hover .nav-icon { background: var(--c1); color: white; transform: scale(1.1) rotate(-5deg); }
.nav-item.active { background: var(--active-bg); color: var(--c1); border: 1px solid var(--border); }
.nav-item.active .nav-icon { background: linear-gradient(135deg, var(--c1), var(--c2)); color: white; box-shadow: 0 4px 12px var(--glow); }
.nav-item.active::before { content: ''; position: absolute; left: 0; top: 20%; height: 60%; width: 3px; background: linear-gradient(var(--c1), var(--c2)); border-radius: 0 4px 4px 0; }

.sidebar-user { margin-top: auto; padding-top: 1rem; border-top: 1.5px solid var(--border); }
.user-avatar { width: 38px; height: 38px; border-radius: 50%; background: linear-gradient(135deg, var(--c1), var(--c2)); display: flex; align-items: center; justify-content: center; color: white; font-weight: 800; font-size: 1rem; box-shadow: 0 4px 12px var(--glow); flex-shrink: 0; }
.user-info-row { display: flex; align-items: center; gap: 10px; padding: 8px 6px; margin-bottom: 6px; }
.user-info-row .uname { font-weight: 700; font-size: 0.9rem; }
.user-info-row .ustatus { font-size: 0.72rem; color: var(--success); display: flex; align-items: center; gap: 4px; }
.online-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--success); animation: pulse 2s infinite; }

/* ---- MAIN CONTENT ---- */
.main-content { margin-left: 260px; flex: 1; padding: 2rem 2.5rem; position: relative; z-index: 1; }
.page-header { margin-bottom: 2rem; }
.page-header h1 { font-size: 2rem; font-weight: 900; background: linear-gradient(135deg, var(--c1), var(--c2)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; animation: slideDown 0.5s ease both; }
.page-header p { color: var(--muted); margin-top: 5px; animation: slideDown 0.5s 0.1s ease both; opacity: 0; animation-fill-mode: forwards; }

/* ============================================================
   CARDS
   ============================================================ */
.card { background: var(--card); border-radius: 22px; border: 1.5px solid var(--border); box-shadow: var(--shadow); padding: 1.8rem; backdrop-filter: blur(16px); transition: transform 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.3s; animation: cardIn 0.6s ease both; position: relative; overflow: hidden; }
.card:hover { transform: translateY(-6px) scale(1.015); box-shadow: var(--shadow), 0 0 40px var(--glow); }
.card::after { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 3px; background: linear-gradient(90deg, var(--c1), var(--c2), var(--c3), var(--c1)); background-size: 200%; animation: shimmer 3s linear infinite; opacity: 0; transition: opacity 0.3s; }
.card:hover::after { opacity: 1; }
.card-title { font-size: 1.05rem; font-weight: 800; color: var(--text); margin-bottom: 1.2rem; display: flex; align-items: center; gap: 8px; }
.card-title .icon { width: 34px; height: 34px; border-radius: 10px; background: linear-gradient(135deg, var(--c1), var(--c2)); display: flex; align-items: center; justify-content: center; color: white; font-size: 0.9rem; box-shadow: 0 4px 12px var(--glow); }

.stat-card { background: linear-gradient(135deg, var(--c1), var(--c2)); color: white; border-radius: 18px; padding: 1.4rem; position: relative; overflow: hidden; box-shadow: 0 6px 24px var(--glow); transition: transform 0.3s, box-shadow 0.3s; animation: cardIn 0.6s ease both; }
.stat-card:hover { transform: translateY(-6px) scale(1.04); box-shadow: 0 14px 36px var(--glow); }
.stat-card::before { content: ''; position: absolute; top: -30px; right: -30px; width: 100px; height: 100px; border-radius: 50%; background: rgba(255, 255, 255, 0.15); }
.stat-card .stv { font-size: 2rem; font-weight: 900; line-height: 1; margin-bottom: 4px; }
.stat-card .stl { font-size: 0.82rem; opacity: 0.85; font-weight: 600; }
.stat-card .sti { font-size: 1.8rem; position: absolute; right: 1.2rem; top: 50%; transform: translateY(-50%); opacity: 0.3; }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.2rem; }
.grid-7 { display: grid; grid-template-columns: repeat(7, 1fr); gap: 1rem; }

.card:nth-child(1) { animation-delay: 0s; } .card:nth-child(2) { animation-delay: 0.1s; } .card:nth-child(3) { animation-delay: 0.2s; } .card:nth-child(4) { animation-delay: 0.3s; } .card:nth-child(5) { animation-delay: 0.4s; }

/* ============================================================
   TIMER, CHAT, SCHEDULE, MODAL, SETTINGS (SENİN ORİJİNAL KODLARIN)
   ============================================================ */
.timer-wrapper { display: flex; flex-direction: column; align-items: center; }
.timer-mode-tabs { display: flex; gap: 0; background: var(--bg2); border-radius: 50px; padding: 5px; margin-bottom: 2rem; }
.timer-mode-tab { padding: 10px 28px; border-radius: 50px; font-weight: 700; cursor: pointer; transition: all 0.3s ease; color: var(--muted); border: none; background: transparent; font-family: 'Outfit', sans-serif; font-size: 0.9rem; }
.timer-mode-tab.active { background: linear-gradient(135deg, var(--c1), var(--c2)); color: white; box-shadow: 0 4px 15px var(--glow); transform: scale(1.05); }
.timer-ring-wrap { position: relative; width: 280px; height: 280px; margin: 1rem auto; }
.timer-svg { position: absolute; top: 0; left: 0; transform: rotate(-90deg); }
.timer-ring-bg { fill: none; stroke: var(--bg2); stroke-width: 10; }
.timer-ring-progress { fill: none; stroke: url(#timerGrad); stroke-width: 10; stroke-linecap: round; stroke-dasharray: 816; stroke-dashoffset: 0; transition: stroke-dashoffset 1s linear; }
.timer-inner { position: absolute; top: 0; left: 0; width: 100%; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.timer-phase { font-size: 0.75rem; font-weight: 800; letter-spacing: 3px; text-transform: uppercase; color: var(--c1); margin-bottom: 4px; }
.timer-display { font-size: 3.8rem; font-weight: 900; background: linear-gradient(135deg, var(--c1), var(--c2)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; line-height: 1; transition: transform 0.3s; }
.timer-running .timer-display { animation: timerPulse 1s ease-in-out infinite; }
.timer-sub { font-size: 0.85rem; color: var(--muted); margin-top: 4px; }
.timer-controls { display: flex; gap: 1rem; margin-top: 2rem; }
.timer-start-btn { width: 160px; height: 54px; font-size: 1rem; letter-spacing: 1px; }

.chat-wrap { display: flex; flex-direction: column; height: calc(100vh - 200px); min-height: 400px; }
.chat-messages { flex: 1; overflow-y: auto; padding: 1.2rem; display: flex; flex-direction: column; gap: 10px; scroll-behavior: smooth; }
.chat-messages::-webkit-scrollbar { width: 4px; } .chat-messages::-webkit-scrollbar-thumb { background: var(--c3); border-radius: 4px; }
.msg-bubble { max-width: 72%; padding: 1