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

    body {
      font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
      background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
      min-height: 100vh;
      padding: 20px;
    }

    .container {
      max-width: 1400px;
      margin: 0 auto;
      background: white;
      border-radius: 16px;
      box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
      overflow: hidden;
      height: calc(100vh - 40px);
      display: flex;
      flex-direction: column;
    }

    .header {
      background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
      color: white;
      padding: 24px 32px;
      border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .header-content {
      display: flex;
      justify-content: space-between;
      align-items: center;
    }

    .title {
      font-size: 28px;
      font-weight: 700;
      display: flex;
      align-items: center;
      gap: 12px;
    }

    .title-icon {
      opacity: 0.9;
    }

    .btn-new {
      background: rgba(255, 255, 255, 0.2);
      color: white;
      border: 2px solid rgba(255, 255, 255, 0.3);
      padding: 12px 24px;
      border-radius: 10px;
      font-size: 15px;
      font-weight: 600;
      cursor: pointer;
      display: flex;
      align-items: center;
      gap: 8px;
      transition: all 0.3s ease;
      backdrop-filter: blur(10px);
    }

    .btn-new:hover {
      background: rgba(255, 255, 255, 0.3);
      transform: translateY(-2px);
      box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
    }

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

    .sidebar {
      width: 320px;
      background: #f8f9fa;
      border-right: 1px solid #e9ecef;
      display: flex;
      flex-direction: column;
    }

    .search-box {
      padding: 20px;
      border-bottom: 1px solid #e9ecef;
      position: relative;
    }

    .search-icon {
      position: absolute;
      left: 36px;
      top: 50%;
      transform: translateY(-50%);
      color: #6c757d;
      pointer-events: none;
    }

    .search-input {
      width: 100%;
      padding: 12px 16px 12px 44px;
      border: 2px solid #e9ecef;
      border-radius: 10px;
      font-size: 14px;
      transition: all 0.3s ease;
      background: white;
    }

    .search-input:focus {
      outline: none;
      border-color: #667eea;
      box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
    }

    .notes-list {
      flex: 1;
      overflow-y: auto;
      padding: 12px;
    }

    .note-item {
      background: white;
      padding: 16px;
      margin-bottom: 8px;
      border-radius: 10px;
      cursor: pointer;
      transition: all 0.2s ease;
      border: 2px solid transparent;
    }

    .note-item:hover {
      transform: translateX(4px);
      box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    }

    .note-item.active {
      border-color: #667eea;
      background: #f0f3ff;
    }

    .note-item-title {
      font-weight: 600;
      font-size: 15px;
      color: #212529;
      margin-bottom: 6px;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }

    .note-item-preview {
      font-size: 13px;
      color: #6c757d;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
      margin-bottom: 8px;
    }

    .note-item-date {
      font-size: 12px;
      color: #adb5bd;
    }

    .editor-container {
      flex: 1;
      display: flex;
      flex-direction: column;
      background: white;
    }

    .editor-header {
      padding: 24px 32px;
      border-bottom: 1px solid #e9ecef;
      display: flex;
      justify-content: space-between;
      align-items: center;
      gap: 20px;
    }

    .note-title-input {
      flex: 1;
      border: none;
      font-size: 24px;
      font-weight: 700;
      color: #212529;
      padding: 8px 0;
    }

    .note-title-input:focus {
      outline: none;
    }

    .note-title-input::placeholder {
      color: #adb5bd;
    }

    .editor-actions {
      display: flex;
      align-items: center;
      gap: 16px;
    }

    .last-saved {
      font-size: 13px;
      color: #6c757d;
    }

    .btn-icon {
      background: #f8f9fa;
      border: none;
      width: 40px;
      height: 40px;
      border-radius: 8px;
      display: flex;
      align-items: center;
      justify-content: center;
      cursor: pointer;
      transition: all 0.2s ease;
      color: #495057;
    }

    .btn-icon:hover {
      background: #fee;
      color: #dc3545;
      transform: scale(1.05);
    }

    .note-content {
      flex: 1;
      border: none;
      padding: 32px;
      font-size: 16px;
      line-height: 1.7;
      color: #212529;
      resize: none;
      font-family: 'Inter', sans-serif;
    }

    .note-content:focus {
      outline: none;
    }

    .note-content::placeholder {
      color: #adb5bd;
    }

    .editor-footer {
      padding: 16px 32px;
      border-top: 1px solid #e9ecef;
      text-align: right;
    }

    .char-count {
      font-size: 13px;
      color: #6c757d;
    }

    .modal {
      position: fixed;
      inset: 0;
      z-index: 1000;
      display: none;
      align-items: center;
      justify-content: center;
    }

    .modal.active {
      display: flex;
    }

    .modal-overlay {
      position: absolute;
      inset: 0;
      background: rgba(0, 0, 0, 0.5);
      backdrop-filter: blur(4px);
    }

    .modal-content {
      position: relative;
      background: white;
      border-radius: 16px;
      padding: 32px;
      max-width: 440px;
      width: 90%;
      box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
      animation: modalSlideIn 0.3s ease;
    }

    @keyframes modalSlideIn {
      from {
        opacity: 0;
        transform: scale(0.95) translateY(20px);
      }
      to {
        opacity: 1;
        transform: scale(1) translateY(0);
      }
    }

    .modal-title {
      font-size: 22px;
      font-weight: 700;
      color: #212529;
      margin-bottom: 12px;
    }

    .modal-text {
      font-size: 15px;
      color: #6c757d;
      margin-bottom: 24px;
      line-height: 1.6;
    }

    .modal-actions {
      display: flex;
      gap: 12px;
      justify-content: flex-end;
    }

    .btn-cancel,
    .btn-confirm {
      padding: 12px 24px;
      border-radius: 8px;
      font-size: 15px;
      font-weight: 600;
      cursor: pointer;
      transition: all 0.2s ease;
      border: none;
    }

    .btn-cancel {
      background: #f8f9fa;
      color: #495057;
    }

    .btn-cancel:hover {
      background: #e9ecef;
    }

    .btn-confirm {
      background: #dc3545;
      color: white;
    }

    .btn-confirm:hover {
      background: #c82333;
      transform: translateY(-2px);
      box-shadow: 0 4px 12px rgba(220, 53, 69, 0.3);
    }

    .empty-state {
      text-align: center;
      padding: 60px 32px;
      color: #adb5bd;
    }

    .empty-state svg {
      width: 80px;
      height: 80px;
      margin-bottom: 20px;
      opacity: 0.3;
    }

    .empty-state p {
      font-size: 16px;
      margin-bottom: 8px;
    }

    .empty-state small {
      font-size: 14px;
    }

    @media (max-width: 768px) {
      .sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid #e9ecef;
      }

      .main-content {
        flex-direction: column;
      }

      .editor-container {
        display: none;
      }

      .editor-container.mobile-active {
        display: flex;
      }

      .sidebar.mobile-hidden {
        display: none;
      }
    }
