/* Özel Ders Paneli Style System */
:root {
    --bg-main: #0b0f19;
    --bg-card: rgba(22, 28, 45, 0.7);
    --bg-card-hover: rgba(30, 39, 62, 0.85);
    --border-color: rgba(255, 255, 255, 0.08);
    --border-highlight: rgba(99, 102, 241, 0.4);
    --primary: #6366f1;
    --primary-hover: #4f46e5;
    --primary-glow: rgba(99, 102, 241, 0.3);
    --accent-blue: #3b82f6;
    --accent-green: #10b981;
    --accent-yellow: #f59e0b;
    --accent-red: #ef4444;
    --text-primary: #f3f4f6;
    --text-secondary: #9ca3af;
    --text-muted: #6b7280;
    --sidebar-width: 260px;
    --radius-lg: 16px;
    --radius-md: 12px;
    --radius-sm: 8px;
    --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg-main);
    color: var(--text-primary);
    line-height: 1.5;
    min-height: 100vh;
    display: flex;
    overflow-x: hidden;
}

body.modal-open {
    overflow: hidden;
}

/* App Wrapper */
.app-container {
    display: flex;
    width: 100vw;
    min-height: 100vh;
    background: radial-gradient(circle at 15% 15%, rgba(99, 102, 241, 0.12) 0%, transparent 40%),
                radial-gradient(circle at 85% 85%, rgba(59, 130, 246, 0.12) 0%, transparent 40%);
}

/* Sidebar Navigation */
.app-sidebar {
    width: var(--sidebar-width);
    background: rgba(15, 21, 37, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-right: 1px solid var(--border-color);
    padding: 24px 16px;
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    z-index: 100;
}

.brand-section {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 24px;
}

.brand-logo-img {
    width: 42px;
    height: 42px;
    background: transparent;
    object-fit: contain;
}

.brand-info h2 {
    font-size: 1.05rem;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: -0.01em;
}

.brand-info span {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 1;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.92rem;
    font-weight: 500;
    border-radius: var(--radius-md);
    transition: var(--transition);
    cursor: pointer;
    border: 1px solid transparent;
}

.nav-item:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.04);
}

.nav-item.active {
    color: #ffffff;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.25) 0%, rgba(59, 130, 246, 0.15) 100%);
    border-color: var(--border-highlight);
    box-shadow: 0 4px 15px var(--primary-glow);
}

.nav-item svg {
    width: 20px;
    height: 20px;
    stroke-width: 2;
}

.sidebar-footer {
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
}

/* Main Content Area */
.app-main {
    flex: 1;
    margin-left: var(--sidebar-width);
    padding: 32px 40px;
    min-height: 100vh;
}

.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 32px;
    flex-wrap: wrap;
    gap: 16px;
}

.user-welcome h1 {
    font-size: 1.6rem;
    font-weight: 700;
    color: #ffffff;
}

.user-welcome p {
    font-size: 0.88rem;
    color: var(--text-secondary);
}

.user-profile-badge {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    padding: 8px 16px;
    border-radius: 40px;
}

.avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6366f1, #3b82f6);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
}

.role-tag {
    font-size: 0.72rem;
    padding: 3px 8px;
    border-radius: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.role-tag.teacher {
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
}

.role-tag.student {
    background: rgba(99, 102, 241, 0.2);
    color: #818cf8;
}

/* Panel Sections */
.tab-section {
    display: none;
    animation: fadeIn 0.3s ease;
}

.tab-section.active {
    display: block;
}

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

/* Cards & Grid Layout */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.panel-card {
    background: var(--bg-card);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    transition: var(--transition);
}

.panel-card:hover {
    border-color: var(--border-highlight);
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
}

.card-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #ffffff;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 600;
}

.badge-green { background: rgba(16, 185, 129, 0.15); color: #34d399; }
.badge-blue { background: rgba(59, 130, 246, 0.15); color: #60a5fa; }
.badge-yellow { background: rgba(245, 158, 11, 0.15); color: #fbbf24; }

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    font-size: 0.9rem;
    font-weight: 600;
    border-radius: var(--radius-md);
    border: none;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
}

.btn-primary {
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
    color: #ffffff;
    box-shadow: 0 4px 14px var(--primary-glow);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #4f46e5 0%, #4338ca 100%);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
}

.btn-meet {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    color: #ffffff;
    width: 100%;
    margin-top: 16px;
    padding: 12px;
}

.btn-meet.btn-meet-sm {
    width: auto;
    margin: 0;
    padding: 8px 14px;
    font-size: 0.82rem;
    white-space: nowrap;
    align-self: center;
    flex-shrink: 0;
}

.btn-meet:hover {
    background: linear-gradient(135deg, #1d4ed8 0%, #1e40af 100%);
}

.btn-meet.disabled,
.btn-meet[disabled] {
    background: rgba(255, 255, 255, 0.08) !important;
    color: var(--text-muted) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    box-shadow: none !important;
    cursor: not-allowed !important;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.8rem;
}

/* Video Player Container (Restricted Embed) */
.video-player-box {
    width: 100%;
    aspect-ratio: 16 / 9;
    max-height: calc(100vh - 230px);
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: #000000;
    border: 1px solid var(--border-color);
    position: relative;
}

.video-player-box iframe,
.video-player-box video,
.video-player-box #lesson-prep-youtube-player {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* Geçmiş Dersler: liste ve ders içeriği */
.lesson-archive-card {
    width: 100%;
    grid-column: 1 / -1;
    color: inherit;
    text-align: left;
    cursor: pointer;
    font: inherit;
}

.lesson-archive-meta {
    display: block;
    margin-top: 5px;
    font-size: 0.82rem;
    color: var(--text-secondary);
}

.lesson-open-arrow {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(99, 102, 241, 0.15);
    color: #a5b4fc;
    font-size: 1.2rem;
}

.lesson-archive-stats,
.lesson-panel-heading {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.lesson-open-label {
    margin-left: auto;
    color: #a5b4fc;
    font-size: 0.84rem;
    font-weight: 600;
}

.lesson-prep-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    flex-wrap: wrap;
}

.lesson-detail-shell {
    grid-column: 1 / -1;
    width: 100%;
}

.lesson-detail-loading {
    grid-column: 1 / -1;
    text-align: center;
}

.lesson-detail-top {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 18px;
}

.lesson-detail-top h2 {
    color: #fff;
    font-size: 1.45rem;
}

.lesson-detail-top p {
    color: var(--text-secondary);
    margin-top: 4px;
    font-size: 0.86rem;
}

.lesson-content-layout {
    display: grid;
    grid-template-columns: minmax(420px, 2.1fr) minmax(250px, 0.95fr);
    gap: 16px;
    align-items: start;
}

.lesson-content-panel,
.lesson-video-panel {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 16px;
}

.lesson-video-panel {
    position: sticky;
    top: 16px;
    align-self: start;
    z-index: 10;
}

.lesson-content-panel h3 {
    color: #fff;
    font-size: 0.98rem;
    margin-bottom: 14px;
}

.lesson-recording-list,
.lesson-file-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.lesson-content-side {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: calc(100vh - 120px);
    overflow-y: auto;
    padding-right: 6px;
}

.lesson-content-side::-webkit-scrollbar {
    width: 6px;
}

.lesson-content-side::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 4px;
}

.lesson-content-side::-webkit-scrollbar-thumb {
    background: rgba(99, 102, 241, 0.35);
    border-radius: 4px;
}

.lesson-content-side::-webkit-scrollbar-thumb:hover {
    background: rgba(99, 102, 241, 0.6);
}

.lesson-recording-item {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 12px;
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.035);
    border: 1px solid transparent;
    border-radius: 10px;
    text-align: left;
    cursor: pointer;
}

.lesson-recording-item.active,
.lesson-recording-item:hover {
    background: rgba(99, 102, 241, 0.14);
    border-color: rgba(99, 102, 241, 0.35);
}

.lesson-recording-item strong,
.lesson-file-item strong {
    display: block;
    color: #fff;
    font-size: 0.79rem;
    line-height: 1.35;
}

.lesson-recording-item small,
.lesson-file-item small {
    display: block;
    color: var(--text-muted);
    margin-top: 3px;
    font-size: 0.7rem;
}

.lesson-material-icon {
    flex: 0 0 28px;
    color: #818cf8;
}

.lesson-access-badge {
    margin-bottom: 12px;
    padding: 8px 12px;
    border: 1px solid rgba(16, 185, 129, 0.32);
    border-radius: 9px;
    color: #34d399;
    background: rgba(16, 185, 129, 0.1);
    font-size: 0.78rem;
    text-align: center;
}

.platform-watch-warning {
    margin-bottom: 10px;
    padding: 11px 13px;
    border: 1px solid rgba(248, 113, 113, 0.65);
    border-radius: 10px;
    background: rgba(127, 29, 29, 0.34);
    color: #fecaca;
    font-size: 0.78rem;
    font-weight: 600;
    line-height: 1.45;
    text-align: center;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.07);
}

.platform-watch-warning strong {
    color: #fff;
}

.lesson-video-empty {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    color: var(--text-secondary);
    padding: 24px;
    text-align: center;
}

.lesson-video-caption {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
    padding-top: 12px;
}

.lesson-video-caption h3 {
    color: #fff;
    font-size: 0.98rem;
}

.lesson-video-caption span {
    color: var(--text-muted);
    font-size: 0.78rem;
    white-space: nowrap;
}

.lesson-panel-heading {
    justify-content: space-between;
    margin-bottom: 12px;
}

.lesson-panel-heading h3 {
    margin-bottom: 0;
}

.lesson-file-item {
    position: relative;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.035);
    border-radius: 10px;
}

.lesson-file-item a {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
    min-width: 0;
    text-decoration: none;
}

.lesson-file-icon {
    display: grid;
    place-items: center;
    flex: 0 0 38px;
    height: 38px;
    border-radius: 8px;
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
    font-size: 0.62rem;
    font-weight: 800;
}

.lesson-file-delete {
    border: 0;
    background: transparent;
    color: #f87171;
    cursor: pointer;
    font-size: 1.1rem;
}

.lesson-empty-state,
.lesson-notes-text {
    color: var(--text-secondary);
    font-size: 0.82rem;
    line-height: 1.55;
}

.lesson-notes-input {
    resize: vertical;
    line-height: 1.5;
}

.lesson-notes-save {
    width: 100%;
    margin-top: 10px;
}

/* Lesson Homework Panel */
.lesson-homework-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.lesson-homework-card {
    background: rgba(255, 255, 255, 0.035);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 10px;
    padding: 12px;
    transition: border-color 0.2s;
}

.lesson-homework-card:hover {
    border-color: rgba(99, 102, 241, 0.3);
}

.lesson-homework-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 8px;
}

.lesson-homework-header strong {
    display: block;
    color: #fff;
    font-size: 0.82rem;
    line-height: 1.35;
}

.lesson-homework-header small {
    display: block;
    color: var(--text-muted);
    margin-top: 3px;
    font-size: 0.7rem;
}

.lesson-homework-desc {
    color: var(--text-secondary);
    font-size: 0.8rem;
    line-height: 1.45;
    margin-top: 6px;
}

.lesson-homework-note {
    background: rgba(99, 102, 241, 0.1);
    padding: 8px 10px;
    border-radius: 8px;
    font-size: 0.78rem;
    color: var(--text-secondary);
    margin-top: 8px;
    line-height: 1.45;
}

.lesson-filter-bar {
    display: flex;
    align-items: flex-end;
    gap: 12px;
    flex-wrap: wrap;
    padding: 14px;
    background: rgba(18, 25, 44, 0.72);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
}

.lesson-filter-group {
    min-width: 190px;
}

.lesson-filter-group label {
    display: block;
    margin-bottom: 5px;
    color: var(--text-secondary);
    font-size: 0.75rem;
    font-weight: 600;
}

.lesson-filter-group .form-control {
    padding: 8px 12px;
}

.lesson-filter-count {
    margin-left: auto;
    padding: 8px 12px;
    color: #a5b4fc;
    font-size: 0.8rem;
    font-weight: 700;
}

.filter-clear-button {
    min-height: 38px;
    padding: 8px 14px;
    white-space: nowrap;
}

.lesson-type-options {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.lesson-type-option {
    cursor: pointer;
}

.lesson-type-option input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.lesson-type-option span {
    display: grid;
    place-items: center;
    min-height: 46px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-secondary);
    font-weight: 700;
    transition: var(--transition);
}

.lesson-type-option input:checked + span {
    color: #fff;
    border-color: #6366f1;
    background: rgba(99, 102, 241, 0.25);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.12);
}

.automatic-time-field[readonly] {
    cursor: not-allowed;
    color: #c7d2fe;
    background: rgba(99, 102, 241, 0.12);
    border-color: rgba(99, 102, 241, 0.42);
}

.lesson-prep-video-form {
    padding: 14px;
    border: 1px solid rgba(99, 102, 241, 0.28);
    border-radius: 12px;
    background: rgba(99, 102, 241, 0.07);
}

.lesson-prep-video-heading,
.prep-video-row-fields,
.prep-video-progress-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.lesson-prep-video-heading label {
    margin-bottom: 3px;
}

.lesson-prep-video-heading small,
.prep-video-help,
#lesson-prep-video-panel .lesson-panel-heading small {
    display: block;
    color: var(--text-muted);
    font-size: 0.72rem;
    line-height: 1.4;
}

.lesson-prep-video-rows,
.prep-video-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 12px;
}

.lesson-prep-video-row {
    padding: 10px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    background: rgba(7, 12, 25, 0.35);
}

.prep-video-row-fields .form-control {
    flex: 1;
}

.prep-video-remove-button,
.prep-video-delete-button {
    border: 1px solid rgba(239, 68, 68, 0.3);
    background: rgba(239, 68, 68, 0.1);
    color: #f87171;
    cursor: pointer;
}

.prep-video-remove-button {
    flex: 0 0 38px;
    height: 38px;
    border-radius: 9px;
    font-size: 1.2rem;
}

.prep-video-validation-status {
    min-height: 18px;
    margin-top: 7px;
    font-size: 0.72rem;
    line-height: 1.4;
}

.prep-video-validation-status.checking {
    color: #fbbf24;
}

.prep-video-validation-status.success {
    color: #34d399;
}

.prep-video-validation-status.error {
    color: #f87171;
}

.youtube-embed-test-holder,
.prep-video-validation-player {
    position: fixed;
    left: -10000px;
    top: 0;
    width: 320px;
    height: 180px;
    overflow: hidden;
    pointer-events: none;
}

.prep-video-card {
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 11px;
    background: rgba(255, 255, 255, 0.025);
}

.prep-video-play-button {
    display: grid;
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 10px;
    align-items: center;
    width: 100%;
    padding: 9px;
    border: 0;
    background: transparent;
    color: var(--text-primary);
    text-align: left;
    cursor: pointer;
}

.prep-video-play-button:hover {
    background: rgba(99, 102, 241, 0.1);
}

.prep-video-play-button img {
    width: 76px;
    aspect-ratio: 16 / 9;
    border-radius: 7px;
    object-fit: cover;
    background: #080b13;
}

.prep-video-play-button b,
.prep-video-play-button small {
    display: block;
}

.prep-video-play-button b {
    color: #fff;
    font-size: 0.76rem;
    line-height: 1.35;
}

.prep-video-play-button small {
    margin-top: 4px;
    color: #a5b4fc;
    font-size: 0.68rem;
}

.prep-video-progress {
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding: 9px 10px 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    color: var(--text-secondary);
}

.prep-video-progress-head {
    font-size: 0.7rem;
}

.prep-video-progress-head strong {
    color: #34d399;
}

.prep-video-progress-track {
    height: 6px;
    overflow: hidden;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
}

.prep-video-progress-track span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #6366f1, #34d399);
}

.prep-video-progress small {
    color: var(--text-muted);
    font-size: 0.65rem;
    line-height: 1.35;
}

.prep-video-delete-button {
    width: calc(100% - 18px);
    margin: 0 9px 9px;
    padding: 6px 8px;
    border-radius: 7px;
    font-size: 0.68rem;
}

.video-notes-panel {
    min-width: 0;
}

.video-note-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 310px;
    overflow-y: auto;
    padding-right: 3px;
}

.video-note-item {
    padding: 10px;
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 10px;
}

.video-note-item.student-note {
    background: rgba(59, 130, 246, 0.1);
    border-color: rgba(96, 165, 250, 0.22);
}

.video-note-item.teacher-note {
    background: rgba(16, 185, 129, 0.1);
    border-color: rgba(52, 211, 153, 0.22);
}

.video-note-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 6px;
}

.video-note-meta strong {
    color: #fff;
    font-size: 0.72rem;
}

.video-note-meta button {
    padding: 4px 7px;
    border: 1px solid rgba(129, 140, 248, 0.32);
    border-radius: 7px;
    background: rgba(99, 102, 241, 0.12);
    color: #c7d2fe;
    font-size: 0.65rem;
    cursor: pointer;
}

.video-note-item p {
    margin: 0;
    color: var(--text-primary);
    font-size: 0.76rem;
    line-height: 1.45;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.video-note-item > small {
    display: block;
    margin-top: 6px;
    color: var(--text-muted);
    font-size: 0.62rem;
}

.video-note-form {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.07);
}

.video-note-position {
    color: #fbbf24;
    font-size: 0.7rem;
    font-weight: 700;
}

.video-note-form textarea {
    min-height: 78px;
    resize: vertical;
    font-size: 0.78rem;
}

.video-note-form .btn {
    width: 100%;
}

#lesson-prep-youtube-player,
#lesson-prep-youtube-player iframe {
    width: 100%;
    height: 100%;
}

.quiz-assignment-title {
    margin-bottom: 18px;
    padding: 12px 14px;
    border: 1px solid rgba(99, 102, 241, 0.32);
    border-radius: var(--radius-md);
    background: rgba(99, 102, 241, 0.1);
    color: #c7d2fe;
    font-weight: 700;
}

.quiz-date-fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.quiz-assignment-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 12px 0;
}

.quiz-assignment-chip {
    padding: 6px 9px;
    border: 1px solid rgba(52, 211, 153, 0.25);
    border-radius: 999px;
    background: rgba(16, 185, 129, 0.1);
    color: #a7f3d0;
    font-size: 0.72rem;
    font-weight: 600;
}

.quiz-access-dates {
    margin: 10px 0;
    color: var(--text-secondary);
    font-size: 0.8rem;
}

.quiz-option-count {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.quiz-form-help {
    margin: 4px 0 12px;
    color: var(--text-muted);
    font-size: 0.78rem;
}

.quiz-answer-key,
.student-optical-sheet {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.optical-row {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
    padding: 9px 10px;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.025);
}

.optical-row > strong {
    display: grid;
    place-items: center;
    flex: 0 0 28px;
    height: 28px;
    border-radius: 8px;
    background: rgba(99, 102, 241, 0.14);
    color: #c7d2fe;
    font-size: 0.78rem;
}

.optical-options {
    display: flex;
    align-items: center;
    gap: 5px;
    min-width: 0;
}

.optical-choice {
    cursor: pointer;
}

.optical-choice input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.optical-choice span {
    display: grid;
    place-items: center;
    min-width: 30px;
    height: 30px;
    padding: 0 7px;
    border: 1px solid rgba(156, 163, 175, 0.3);
    border-radius: 999px;
    color: var(--text-secondary);
    font-size: 0.76rem;
    font-weight: 700;
    transition: var(--transition);
}

.optical-choice:hover span {
    border-color: #818cf8;
    color: #e0e7ff;
}

.optical-choice input:checked + span {
    border-color: #6366f1;
    background: #4f46e5;
    color: #fff;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.16);
}

.optical-blank span {
    min-width: 42px;
    border-radius: 8px;
    font-size: 0.67rem;
}

.quiz-solve-modal,
.quiz-results-modal {
    max-width: 780px;
}

.quiz-pdf-button {
    display: inline-flex;
    margin-bottom: 16px;
    padding: 9px 12px;
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 9px;
    background: rgba(59, 130, 246, 0.1);
    color: #93c5fd;
    font-size: 0.82rem;
    font-weight: 600;
    text-decoration: none;
}

.quiz-pdf-button[hidden] {
    display: none;
}

.quiz-result-summary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px;
    border: 1px solid rgba(16, 185, 129, 0.25);
    border-radius: 10px;
    background: rgba(16, 185, 129, 0.08);
}

.quiz-stat {
    padding: 5px 8px;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
}

.quiz-stat.correct {
    background: rgba(16, 185, 129, 0.14);
    color: #6ee7b7;
}

.quiz-stat.wrong {
    background: rgba(239, 68, 68, 0.14);
    color: #fca5a5;
}

.quiz-stat.blank {
    background: rgba(156, 163, 175, 0.14);
    color: #d1d5db;
}

.quiz-results-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.quiz-result-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 14px;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.03);
}

.quiz-result-row > div:first-child {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.quiz-result-row > div:first-child span,
.quiz-results-empty {
    color: var(--text-muted);
    font-size: 0.78rem;
}

.quiz-result-counts {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 6px;
    flex-wrap: wrap;
}

@media (max-width: 1180px) {
    .lesson-content-layout {
        grid-template-columns: minmax(380px, 1.7fr) minmax(230px, 0.8fr);
    }
}

@media (max-width: 800px) {
    .lesson-content-layout,
    .lesson-content-side {
        grid-template-columns: 1fr;
    }

    .lesson-video-panel {
        position: static;
    }

    .lesson-content-side {
        grid-column: auto;
        max-height: none;
        overflow-y: visible;
        padding-right: 0;
    }

    .lesson-detail-top {
        align-items: flex-start;
        flex-direction: column;
    }

    .lesson-open-label {
        width: 100%;
        margin-left: 0;
    }

    .lesson-filter-group {
        width: 100%;
    }

    .lesson-filter-count {
        width: 100%;
        margin-left: 0;
    }

    .filter-clear-button {
        width: 100%;
        justify-content: center;
    }

    .quiz-date-fields {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .quiz-answer-key,
    .student-optical-sheet {
        grid-template-columns: 1fr;
    }

    .quiz-result-row {
        align-items: flex-start;
        flex-direction: column;
    }

    .quiz-result-counts {
        justify-content: flex-start;
    }
}

@media (max-width: 480px) {
    .quiz-option-count {
        grid-template-columns: 1fr;
    }

    .optical-row {
        align-items: flex-start;
    }

    .optical-options {
        flex-wrap: wrap;
    }
}

/* Modal Form Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px 16px;
    overflow-y: auto;
    overscroll-behavior: contain;
    z-index: 1000;
}

.modal-overlay.active {
    display: flex;
}

.modal-box {
    background: #131a2e;
    border: 1px solid var(--border-highlight);
    border-radius: var(--radius-lg);
    width: 90%;
    max-width: 540px;
    max-height: calc(100vh - 48px);
    max-height: calc(100dvh - 48px);
    padding: 32px;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    scrollbar-gutter: stable;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
}

.modal-box::-webkit-scrollbar {
    width: 8px;
}

.modal-box::-webkit-scrollbar-thumb {
    border-radius: 999px;
    background: rgba(156, 163, 175, 0.35);
}

.modal-box::-webkit-scrollbar-track {
    background: transparent;
}

@media (max-height: 720px), (max-width: 600px) {
    .modal-overlay {
        align-items: flex-start;
        padding: 12px;
    }

    .modal-box {
        width: 100%;
        max-height: calc(100vh - 24px);
        max-height: calc(100dvh - 24px);
        padding: 22px;
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.modal-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: #ffffff;
}

.modal-close {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 1.5rem;
    cursor: pointer;
}

.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 6px;
}

.form-control {
    width: 100%;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: #ffffff;
    font-size: 0.9rem;
    outline: none;
    transition: var(--transition);
}

.form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-glow);
}

/* Custom Confirm Modal & Toast Container */
.confirm-box {
    background: #131a2e;
    border: 1px solid var(--border-highlight);
    border-radius: var(--radius-lg);
    width: 90%;
    max-width: 440px;
    padding: 28px;
    text-align: center;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.6);
    animation: modalPop 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

.confirm-icon {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
}

.confirm-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 8px;
}

.confirm-text {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 24px;
    line-height: 1.5;
}

.confirm-actions {
    display: flex;
    gap: 12px;
}

.btn-danger {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(239, 68, 68, 0.4);
}

.btn-danger:hover {
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-primary);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
}

/* Floating Toast Notifications */
#toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 2000;
}

.toast {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    background: rgba(22, 28, 45, 0.95);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: #ffffff;
    font-size: 0.9rem;
    font-weight: 500;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
    animation: toastSlide 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    min-width: 280px;
}

.toast.toast-success { border-left: 4px solid var(--accent-green); }
.toast.toast-error { border-left: 4px solid var(--accent-red); }
.toast.toast-warning { border-left: 4px solid #f59e0b; }
.toast.toast-info { border-left: 4px solid var(--primary); }

@keyframes toastSlide {
    from { opacity: 0; transform: translateX(50px); }
    to { opacity: 1; transform: translateX(0); }
}

/* ==========================================================================
   Ders & Etkinlik Takvimi (Calendar Module Styles)
   ========================================================================== */
.calendar-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.calendar-title-group {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.calendar-title-group h2 {
    font-size: 1.35rem;
    font-weight: 700;
    color: #ffffff;
    margin: 0;
}

.calendar-nav-group {
    display: flex;
    gap: 6px;
}

.calendar-view-selector {
    display: flex;
    background: rgba(255, 255, 255, 0.05);
    padding: 4px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.calendar-view-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    padding: 6px 14px;
    font-size: 0.85rem;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.calendar-view-btn.active,
.calendar-view-btn:hover {
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
    color: #ffffff;
    box-shadow: 0 2px 10px rgba(99, 102, 241, 0.3);
}

.calendar-card {
    padding: 20px;
    overflow-x: auto;
}

/* Month View Grid */
.calendar-month-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(120px, 1fr));
    gap: 8px;
}

.calendar-day-header {
    text-align: center;
    padding: 10px 4px;
    font-weight: 600;
    font-size: 0.82rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.calendar-day-cell {
    min-height: 110px;
    background: rgba(255, 255, 255, 0.025);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    padding: 8px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    transition: background 0.2s, border-color 0.2s;
    cursor: pointer;
}

.calendar-day-cell:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(99, 102, 241, 0.25);
}

.calendar-day-cell.other-month {
    opacity: 0.35;
    background: rgba(0, 0, 0, 0.1);
}

.calendar-day-cell.today {
    border: 1.5px solid #6366f1;
    background: rgba(99, 102, 241, 0.08);
}

.calendar-day-num {
    font-size: 0.82rem;
    font-weight: 700;
    color: #e0e7ff;
    display: inline-block;
    width: 24px;
    height: 24px;
    line-height: 24px;
    text-align: center;
    border-radius: 50%;
}

.calendar-day-cell.today .calendar-day-num {
    background: #6366f1;
    color: #ffffff;
}

.calendar-events-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-top: 2px;
}

/* Event Chips */
.cal-chip {
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 0.72rem;
    font-weight: 600;
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: flex;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    transition: transform 0.15s;
}

.cal-chip:hover {
    transform: translateY(-1px);
}

.cal-chip.cal-lesson {
    background: rgba(99, 102, 241, 0.25);
    color: #c7d2fe;
    border: 1px solid rgba(99, 102, 241, 0.4);
}

.cal-chip.cal-completed {
    background: rgba(16, 185, 129, 0.2);
    color: #6ee7b7;
    border: 1px solid rgba(16, 185, 129, 0.35);
}

.cal-chip.cal-homework {
    background: rgba(245, 158, 11, 0.2);
    color: #fde68a;
    border: 1px solid rgba(245, 158, 11, 0.35);
}

/* Week View Grid */
.calendar-week-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(130px, 1fr));
    gap: 10px;
}

.calendar-week-col {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-height: 250px;
}

.calendar-week-header {
    text-align: center;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.calendar-week-header strong {
    display: block;
    font-size: 0.85rem;
    color: #ffffff;
}

.calendar-week-header small {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* Day View Timeline */
.calendar-day-view {
    max-width: 700px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.calendar-event-card {
    background: rgba(255, 255, 255, 0.035);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    transition: border-color 0.2s;
}

.calendar-event-card:hover {
    border-color: rgba(99, 102, 241, 0.4);
}

/* ==========================================================================
   Dashboard & Finans Modülleri Stilleri
   ========================================================================== */

/* Stat Grid */
.dashboard-stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.stat-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 14px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
}

.stat-card:hover {
    transform: translateY(-2px);
    border-color: rgba(99, 102, 241, 0.3);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    flex-shrink: 0;
}

.stat-icon.purple { background: rgba(99, 102, 241, 0.18); color: #818cf8; }
.stat-icon.blue { background: rgba(59, 130, 246, 0.18); color: #60a5fa; }
.stat-icon.green { background: rgba(16, 185, 129, 0.18); color: #34d399; }
.stat-icon.yellow { background: rgba(245, 158, 11, 0.18); color: #fbbf24; }
.stat-icon.red { background: rgba(239, 68, 68, 0.18); color: #f87171; }

.stat-info h4 {
    margin: 0;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-info .stat-value {
    font-size: 1.6rem;
    font-weight: 800;
    color: #ffffff;
    margin-top: 2px;
}

/* Hero Next Lesson Card */
.dashboard-hero {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.9) 0%, rgba(15, 23, 42, 0.95) 100%);
    border: 1.5px solid rgba(99, 102, 241, 0.35);
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 24px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.dashboard-hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.15) 0%, transparent 70%);
    pointer-events: none;
}

.hero-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.hero-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: #ffffff;
    margin: 6px 0;
}

/* Finance Tables & Badges */
.finance-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.finance-table th {
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-muted);
    font-weight: 600;
    text-align: left;
    padding: 12px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 0.8rem;
    text-transform: uppercase;
}

.finance-table td {
    padding: 14px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    color: #e2e8f0;
}

.finance-table tr:hover td {
    background: rgba(255, 255, 255, 0.02);
}

.payment-toggle-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
}

.payment-toggle-btn.paid {
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.4);
}

.payment-toggle-btn.paid:hover {
    background: rgba(16, 185, 129, 0.35);
}

.payment-toggle-btn.unpaid {
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.payment-toggle-btn.unpaid:hover {
    background: rgba(239, 68, 68, 0.3);
}

/* ==========================================
   RESPONSIVE DESIGN & MOBILE OPTIMIZATIONS
   ========================================== */

/* Mobile Header Bar (Default Hidden on Desktop) */
.mobile-header-bar {
    display: none;
    align-items: center;
    justify-content: space-between;
    height: 60px;
    padding: 0 16px;
    background: rgba(11, 15, 25, 0.92);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 900;
    margin: -32px -40px 24px -40px;
}

.mobile-menu-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    color: #ffffff;
    cursor: pointer;
    transition: var(--transition);
}

.mobile-menu-toggle:active {
    background: rgba(99, 102, 241, 0.2);
}

.mobile-brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.mobile-brand-logo {
    width: 32px;
    height: 32px;
    object-fit: contain;
}

.mobile-brand span {
    font-weight: 700;
    font-size: 1.05rem;
    color: #ffffff;
}

.mobile-avatar-btn {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6366f1 0%, #3b82f6 100%);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    overflow: hidden;
    border: 1.5px solid rgba(99, 102, 241, 0.5);
}

.mobile-avatar-btn img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Sidebar Backdrop */
.sidebar-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 1050;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.sidebar-backdrop.active {
    opacity: 1;
    visibility: visible;
}

/* Table Responsive Wrapper */
.table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: var(--radius-md);
    margin-top: 14px;
}

/* Tablet & Mobile Breakpoint (<= 1024px) */
@media (max-width: 1024px) {
    .app-sidebar {
        position: fixed;
        top: 0;
        left: 0;
        bottom: 0;
        width: 280px;
        max-width: 82vw;
        height: 100vh;
        height: 100dvh;
        z-index: 1100;
        transform: translateX(-100%);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: 15px 0 40px rgba(0, 0, 0, 0.6);
        border-right: 1px solid var(--border-highlight);
    }

    .app-sidebar.mobile-open {
        transform: translateX(0);
    }

    .app-main {
        margin-left: 0;
        padding: 0 20px 32px 20px;
        width: 100%;
    }

    .mobile-header-bar {
        display: flex;
        margin: 0 -20px 24px -20px;
    }

    .top-bar {
        margin-bottom: 24px;
        gap: 14px;
    }

    .user-welcome h1 {
        font-size: 1.35rem;
    }

    .dashboard-stat-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 14px;
    }

    .dashboard-detail-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .horizontal-lesson-card {
        padding: 16px;
    }
}

/* Mobile Breakpoint (<= 768px) */
@media (max-width: 768px) {
    .app-main {
        padding: 0 14px 28px 14px;
    }

    .mobile-header-bar {
        margin: 0 -14px 18px -14px;
        padding: 0 14px;
        height: 56px;
    }

    .top-bar {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .user-welcome h1 {
        font-size: 1.2rem;
    }

    .user-welcome p {
        font-size: 0.8rem;
    }

    /* Dashboard Hero Banner */
    .dashboard-hero {
        padding: 20px 16px !important;
        border-radius: 14px !important;
    }

    .dashboard-hero h2 {
        font-size: 1.2rem !important;
    }

    .dashboard-hero-actions {
        flex-direction: column;
        align-items: stretch;
        width: 100%;
    }

    .dashboard-hero-actions .btn {
        width: 100%;
        justify-content: center;
        text-align: center;
    }

    /* Dersler & Filtreleme */
    .lesson-filter-bar {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
        padding: 14px;
    }

    .lesson-filter-group {
        flex-direction: column;
        align-items: stretch;
        width: 100%;
    }

    .lesson-filter-group select,
    .lesson-filter-group input {
        width: 100%;
        height: 42px;
    }

    .horizontal-lesson-card {
        flex-direction: column;
        align-items: stretch;
        gap: 14px;
        padding: 16px 14px;
    }

    .horizontal-lesson-actions {
        width: 100%;
        display: flex;
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }

    .horizontal-lesson-actions .btn {
        width: 100% !important;
        justify-content: center;
        text-align: center;
    }

    /* Takvim Modülü Mobil */
    .calendar-toolbar {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
        padding: 14px;
    }

    .cal-nav-group {
        width: 100%;
        justify-content: space-between;
    }

    .cal-title {
        text-align: center;
        font-size: 1.1rem;
    }

    .cal-view-switcher {
        width: 100%;
        display: flex;
    }

    .cal-view-btn {
        flex: 1;
        text-align: center;
        padding: 8px 6px;
        font-size: 0.8rem;
    }

    .calendar-month-grid {
        min-width: 540px;
    }

    .calendar-scroll-wrapper {
        width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    /* Finans Modülü Mobil */
    .finance-stat-grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }

    .finance-stat-card {
        padding: 14px 12px;
    }

    .finance-stat-card .stat-value {
        font-size: 1.2rem;
    }

    /* Modallar */
    .modal-box {
        width: 94%;
        padding: 22px 16px;
        border-radius: 16px;
    }

    .modal-header h3 {
        font-size: 1.1rem;
    }
}

/* Small Mobile Breakpoint (<= 480px) */
@media (max-width: 480px) {
    .lesson-prep-video-heading,
    .prep-video-row-fields {
        align-items: stretch;
        flex-direction: column;
    }

    .lesson-prep-video-heading .btn,
    .prep-video-row-fields .btn,
    .prep-video-remove-button {
        width: 100%;
    }

    .prep-video-remove-button {
        flex-basis: 36px;
    }

    .dashboard-stat-grid {
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }

    .stat-card {
        padding: 12px 10px;
    }

    .stat-value {
        font-size: 1.3rem;
    }

    .stat-label {
        font-size: 0.72rem;
    }

    .finance-stat-grid {
        grid-template-columns: 1fr;
        gap: 8px;
    }
}

/* ==========================================
   YENİ ÖĞRENCİ KARTLARI VE ARŞİV TASARIMI
   ========================================== */

.student-subtabs-bar {
    display: flex;
    gap: 10px;
    margin-bottom: 22px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 14px;
}

.student-subtab-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.student-subtab-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-primary);
}

.student-subtab-btn.active {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.25) 0%, rgba(59, 130, 246, 0.18) 100%);
    border-color: var(--border-highlight);
    color: #ffffff;
    box-shadow: 0 4px 15px var(--primary-glow);
}

.badge-count {
    background: rgba(255, 255, 255, 0.15);
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 0.78rem;
    color: #ffffff;
}

.badge-purple {
    background: rgba(147, 51, 234, 0.18);
    color: #c084fc;
    border: 1px solid rgba(147, 51, 234, 0.35);
}

.student-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
    gap: 20px;
}

.student-card-modern {
    background: rgba(22, 28, 45, 0.75);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border-color);
    border-radius: 18px;
    padding: 22px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: var(--transition);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.student-card-modern:hover {
    border-color: var(--border-highlight);
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(99, 102, 241, 0.15);
}

.student-card-modern.status-inactive {
    border-color: rgba(245, 158, 11, 0.3);
    background: rgba(26, 23, 34, 0.75);
}

.student-card-modern.status-archived {
    opacity: 0.85;
    border-color: rgba(147, 51, 234, 0.3);
}

.student-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 18px;
}

.student-profile-info {
    display: flex;
    align-items: center;
    gap: 14px;
}

.student-avatar-box {
    width: 52px;
    height: 52px;
    flex-shrink: 0;
}

.student-avatar-img {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(99, 102, 241, 0.5);
}

.student-avatar-initial {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6366f1 0%, #3b82f6 100%);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    font-weight: 700;
    box-shadow: 0 4px 14px rgba(99, 102, 241, 0.3);
}

.student-name {
    font-size: 1.08rem;
    font-weight: 700;
    color: #ffffff;
    margin: 0 0 2px 0;
}

.student-email {
    font-size: 0.83rem;
    color: var(--text-secondary);
    text-decoration: none;
    display: block;
    word-break: break-all;
}

.student-card-meta {
    background: rgba(11, 15, 25, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-md);
    padding: 14px;
    margin-bottom: 18px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.meta-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.meta-label {
    font-size: 0.72rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.meta-val {
    font-size: 0.85rem;
    color: var(--text-primary);
    font-weight: 600;
}

.student-card-actions {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

@media (max-width: 640px) {
    .student-card-grid {
        grid-template-columns: 1fr;
    }

    .student-card-meta {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .student-card-actions {
        flex-direction: column;
        align-items: stretch;
    }
}

/* ==========================================
   SİTE GENELİ SAĞ TIKLAMA VE KORUMA SİSTEMİ
   ========================================== */

body {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

input, textarea, select, [contenteditable="true"] {
    -webkit-user-select: auto !important;
    -moz-user-select: auto !important;
    -ms-user-select: auto !important;
    user-select: auto !important;
}

/* KORUMALI VİDEO OYNATICI (CHROME EKLENTİSİ & İNDİRME ENGELLEME) */
.protected-video-shell {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000000;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.protected-video-shell iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.video-guard-topbar {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 54px;
    background: transparent;
    z-index: 10;
    pointer-events: auto;
}
