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

        body {
            font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            background: linear-gradient(135deg, #0a0a0a 0%, #1a1a1a 100%);
            color: #fff;
            overflow: hidden;
        }

        /* LAYOUT PRINCIPAL */
        .container {
            display: flex;
            height: 100vh;
        }

        /* SIDEBAR ESQUERDA */
        .left-sidebar {
            width: 280px;
            background: linear-gradient(180deg, #1a1a1a 0%, #0d0d0d 100%);
            border-right: 2px solid #2a2a2a;
            display: flex;
            flex-direction: column;
            overflow: hidden;
        }

        .logo-area {
            padding: 20px;
            background: linear-gradient(135deg, #8b0000 0%, #c0392b 100%);
            text-align: center;
            font-size: 20px;
            font-weight: bold;
            box-shadow: 0 4px 15px rgba(192, 57, 43, 0.3);
        }

        /* CALENDÁRIO */
        .calendar-section {
            padding: 15px;
            border-bottom: 2px solid #2a2a2a;
        }

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

        .calendar-header h3 {
            font-size: 14px;
            color: #c0392b;
        }

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

        .calendar-nav button {
            background: transparent;
            border: 1px solid #fff;
            color: #fff;
            padding: 5px 10px;
            border-radius: 4px;
            cursor: pointer;
            transition: all 0.3s;
            font-weight: bold;
        }

        .calendar-nav button:hover {
            background: #c0392b;
            border-color: #c0392b;
        }

        .calendar-grid {
            display: grid;
            grid-template-columns: repeat(7, 1fr);
            gap: 5px;
        }

        .calendar-day-header {
            text-align: center;
            font-size: 10px;
            color: #888;
            padding: 5px 0;
            font-weight: bold;
        }

        .calendar-day {
            aspect-ratio: 1;
            display: flex;
            align-items: center;
            justify-content: center;
            background: #1a1a1a;
            border-radius: 4px;
            font-size: 12px;
            cursor: pointer;
            transition: all 0.3s;
            border: 1px solid transparent;
        }

        .calendar-day:hover {
            background: #2a2a2a;
            border-color: #c0392b;
        }

        .calendar-day.empty {
            background: transparent;
            cursor: default;
        }

        .calendar-day.today {
            background: #c0392b;
            font-weight: bold;
        }

        .calendar-day.selected {
            background: #8b0000;
            border-color: #c0392b;
            box-shadow: 0 0 10px rgba(192, 57, 43, 0.5);
        }

        /* PLAYLIST SECTIONS */
        .playlist-section {
            padding: 15px;
            border-bottom: 2px solid #2a2a2a;
        }

        .playlist-header {
            display: flex;
            align-items: center;
            gap: 10px;
            margin-bottom: 10px;
            padding-bottom: 10px;
            border-bottom: 1px solid #2a2a2a;
        }

        .playlist-header i {
            color: #c0392b;
        }

        .playlist-header h3 {
            font-size: 14px;
            flex: 1;
        }

        .playlist-date {
            font-size: 11px;
            color: #888;
        }

        .playlist-items {
            display: flex;
            flex-direction: column;
            gap: 8px;
            max-height: 200px;
            overflow-y: auto;
        }

        .playlist-item {
            background: #1a1a1a;
            border-left: 4px solid #c0392b;
            padding: 10px;
            border-radius: 4px;
            cursor: pointer;
            transition: all 0.3s;
        }

        .playlist-item:hover {
            background: #2a2a2a;
            transform: translateX(5px);
        }

        .playlist-item-title {
            font-size: 12px;
            font-weight: bold;
            margin-bottom: 4px;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        .playlist-item-duration {
            font-size: 10px;
            color: #888;
        }

        .backup-drop-zone {
            min-height: 100px;
            border: 2px dashed #444;
            border-radius: 8px;
            display: flex;
            align-items: center;
            justify-content: center;
            color: #666;
            font-size: 12px;
            text-align: center;
            padding: 20px;
        }

        .backup-drop-zone.drag-over {
            border-color: #c0392b;
            background: rgba(192, 57, 43, 0.1);
            color: #c0392b;
        }

        /* MAIN CONTENT */
        .main-content {
            flex: 1;
            display: flex;
            flex-direction: column;
            overflow: hidden;
        }

        .content-wrapper {
            flex: 1;
            display: flex;
            overflow: hidden;
        }

        .grid-area {
            flex: 1;
            display: flex;
            flex-direction: column;
            overflow: hidden;
        }

        /* RIGHT LIBRARY */
        .right-library {
            width: 280px;
            background: linear-gradient(180deg, #0a0a0a 0%, #1a1a1a 100%);
            border-left: 2px solid #2a2a2a;
            display: flex;
            flex-direction: column;
            overflow-y: auto;
            overflow-x: hidden;
        }

        .library-header {
            padding: 15px;
            border-bottom: 2px solid #2a2a2a;
            background: #0a0a0a;
            flex-shrink: 0;
        }

        .library-title {
            font-size: 14px;
            font-weight: bold;
            color: #c0392b;
            margin-bottom: 10px;
            display: flex;
            align-items: center;
            gap: 8px;
        }

        .library-filter {
            width: 100%;
            padding: 8px;
            background: #1a1a1a;
            border: 1px solid #2a2a2a;
            border-radius: 6px;
            color: #fff;
            font-size: 12px;
        }

        .library-list {
            flex: 1;
            padding: 10px;
        }

        .library-video {
            background: linear-gradient(135deg, #1a1a1a 0%, #2a2a2a 100%);
            border-radius: 8px;
            padding: 10px;
            margin-bottom: 8px;
            cursor: grab;
            transition: all 0.3s;
            border: 2px solid transparent;
        }

        .library-video:hover {
            transform: translateX(-5px);
            box-shadow: 0 4px 15px rgba(192, 57, 43, 0.3);
            border-color: #c0392b;
        }

        .library-video:active {
            cursor: grabbing;
        }

        .library-video-title {
            font-size: 12px;
            font-weight: bold;
            color: #fff;
            margin-bottom: 4px;
            overflow: hidden;
            text-overflow: ellipsis;
            white-space: nowrap;
        }

        .library-video-duration {
            font-size: 11px;
            color: #888;
            font-family: 'Courier New', monospace;
        }

        /* TOP BAR */
        .top-bar {
            background: linear-gradient(135deg, #1a1a1a 0%, #2a2a2a 100%);
            padding: 15px 30px;
            display: flex;
            justify-content: space-between;
            align-items: center;
            border-bottom: 2px solid #c0392b;
            box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
        }

        .top-bar-title {
            font-size: 18px;
            font-weight: bold;
            color: #c0392b;
        }

        .top-bar-controls {
            display: flex;
            gap: 20px;
            align-items: center;
        }

        .clock {
            font-family: 'Courier New', monospace;
            font-size: 22px;
            font-weight: bold;
            color: #fff;
            background: #0a0a0a;
            padding: 8px 16px;
            border-radius: 8px;
            box-shadow: 0 0 20px rgba(192, 57, 43, 0.3);
        }

        /* GRADE */
        .grade-container {
            flex: 1;
            padding: 20px;
            overflow-y: auto;
            overflow-x: hidden;
        }

        .grade-wrapper {
            position: relative;
            min-height: 1500px;
        }

        .grade-timeline {
            display: flex;
        }

        .grade-hours {
            width: 60px;
            flex-shrink: 0;
        }

        .hour-label {
            height: 60px;
            display: flex;
            align-items: center;
            justify-content: center;
            font-family: 'Courier New', monospace;
            font-size: 14px;
            font-weight: bold;
            color: #888;
            background: #1a1a1a;
            border-bottom: 1px solid #2a2a2a;
        }

        .grade-content {
            flex: 1;
            position: relative;
            background: #0a0a0a;
        }

        .time-grid {
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
        }

        .time-row {
            height: 60px;
            border-bottom: 1px solid #2a2a2a;
            position: relative;
        }

        .time-marker {
            position: absolute;
            width: 2px;
            height: 100%;
            background: #c0392b;
            box-shadow: 0 0 10px rgba(192, 57, 43, 0.8);
            z-index: 10;
            pointer-events: none;
            top: 0;
        }

        .time-marker::before {
            content: '';
            position: absolute;
            left: -4px;
            top: -6px;
            width: 10px;
            height: 10px;
            background: #c0392b;
            border-radius: 50%;
            box-shadow: 0 0 10px rgba(192, 57, 43, 1);
        }

        .program-block {
            position: absolute;
            background: #3498db;
            border-radius: 8px;
            padding: 10px;
            cursor: move;
            transition: all 0.3s;
            border: 2px solid rgba(255, 255, 255, 0.1);
            overflow: hidden;
        }

        .program-block:hover {
            transform: translateY(-2px);
            box-shadow: 0 8px 20px rgba(0, 0, 0, 0.5);
            border-color: rgba(255, 255, 255, 0.3);
        }

        .program-title {
            font-size: 13px;
            font-weight: bold;
            margin-bottom: 4px;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        .program-time {
            font-size: 11px;
            opacity: 0.8;
        }

        .program-delete {
            position: absolute;
            top: 5px;
            right: 5px;
            background: rgba(0, 0, 0, 0.5);
            width: 24px;
            height: 24px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            opacity: 0;
            transition: all 0.3s;
        }

        .program-block:hover .program-delete {
            opacity: 1;
        }

        .program-delete:hover {
            background: #c0392b;
            transform: scale(1.2);
        }

        /* BUTTONS */
        .btn {
            padding: 10px 20px;
            border: none;
            border-radius: 8px;
            font-size: 14px;
            font-weight: bold;
            cursor: pointer;
            transition: all 0.3s;
            display: inline-flex;
            align-items: center;
            gap: 8px;
        }

        .btn-primary {
            background: linear-gradient(135deg, #c0392b 0%, #8b0000 100%);
            color: #fff;
            box-shadow: 0 4px 15px rgba(192, 57, 43, 0.3);
        }

        .btn-primary:hover {
            transform: translateY(-2px);
            box-shadow: 0 6px 20px rgba(192, 57, 43, 0.5);
        }

        .btn-secondary {
            background: #2a2a2a;
            color: #fff;
        }

        .btn-secondary:hover {
            background: #3a3a3a;
        }

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

        ::-webkit-scrollbar-track {
            background: #0a0a0a;
        }

        ::-webkit-scrollbar-thumb {
            background: #2a2a2a;
            border-radius: 4px;
        }

        ::-webkit-scrollbar-thumb:hover {
            background: #c0392b;
        }

        /* TABS */
        .tabs {
            display: flex;
            gap: 10px;
            padding: 0 30px;
            background: #1a1a1a;
            border-bottom: 2px solid #2a2a2a;
        }

        .tab {
            padding: 15px 25px;
            cursor: pointer;
            border-bottom: 3px solid transparent;
            transition: all 0.3s;
            font-weight: 500;
        }

        .tab:hover {
            background: #2a2a2a;
        }

        .tab.active {
            border-bottom-color: #c0392b;
            color: #c0392b;
        }

        .tab-content {
            display: none;
        }

        .tab-content.active {
            display: block;
            height: calc(100vh - 150px);
            overflow-y: auto;
        }

        /* MODE TOGGLE */
        .mode-toggle {
            display: flex;
            gap: 0;
            background: #0a0a0a;
            border-radius: 8px;
            overflow: hidden;
            border: 2px solid #2a2a2a;
        }

        .mode-btn {
            padding: 8px 16px;
            background: #1a1a1a;
            color: #888;
            border: none;
            cursor: pointer;
            font-size: 12px;
            font-weight: bold;
            transition: all 0.3s;
            display: flex;
            align-items: center;
            gap: 6px;
        }

        .mode-btn:hover {
            background: #2a2a2a;
            color: #fff;
        }

        .mode-btn.active {
            background: #c0392b;
            color: #fff;
        }

        /* MODAL */
        .modal-overlay {
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: rgba(0, 0, 0, 0.8);
            display: none;
            align-items: center;
            justify-content: center;
            z-index: 1000;
        }

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

        .modal {
            background: linear-gradient(135deg, #1a1a1a 0%, #2a2a2a 100%);
            border-radius: 12px;
            width: 450px;
            box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
            border: 2px solid #c0392b;
        }

        .modal-header {
            padding: 20px;
            border-bottom: 2px solid #2a2a2a;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }

        .modal-title {
            font-size: 18px;
            font-weight: bold;
            color: #c0392b;
        }

        .modal-close {
            background: none;
            border: none;
            color: #888;
            font-size: 24px;
            cursor: pointer;
            width: 32px;
            height: 32px;
            display: flex;
            align-items: center;
            justify-content: center;
            border-radius: 50%;
            transition: all 0.3s;
        }

        .modal-close:hover {
            background: #c0392b;
            color: #fff;
        }

        .modal-tabs {
            display: flex;
            border-bottom: 2px solid #2a2a2a;
        }

        .modal-tab {
            flex: 1;
            padding: 15px;
            text-align: center;
            cursor: pointer;
            background: #1a1a1a;
            border: none;
            color: #888;
            font-weight: bold;
            transition: all 0.3s;
        }

        .modal-tab:hover {
            background: #2a2a2a;
            color: #fff;
        }

        .modal-tab.active {
            background: #c0392b;
            color: #fff;
        }

        .modal-body {
            padding: 30px;
        }

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

        .form-label {
            display: block;
            margin-bottom: 8px;
            font-weight: bold;
            color: #c0392b;
            font-size: 14px;
        }

        .form-input {
            width: 100%;
            padding: 12px;
            background: #0a0a0a;
            border: 2px solid #2a2a2a;
            border-radius: 8px;
            color: #fff;
            font-size: 14px;
            transition: all 0.3s;
        }

        .form-input:focus {
            outline: none;
            border-color: #c0392b;
            box-shadow: 0 0 10px rgba(192, 57, 43, 0.3);
        }

        .modal-footer {
            padding: 20px;
            border-top: 2px solid #2a2a2a;
            display: flex;
            justify-content: flex-end;
            gap: 10px;
        }

        /* ANIMAÇÕES */
        @keyframes pulse {
            0%, 100% {
                opacity: 1;
                transform: scale(1);
            }
            50% {
                opacity: 0.5;
                transform: scale(0.8);
            }
        }
